コード例 #1
0
        public bool VerifyMd5(string md5ToCompare)
        {
            System.StringComparer comparer = System.StringComparer.OrdinalIgnoreCase;

            if (comparer.Compare(ComputeMd5(), md5ToCompare) != 0)
            {
                return(false);
            }

            return(true);
        }
コード例 #2
0
ファイル: cMD5Hash.cs プロジェクト: shkumat/MyTypes
 public bool IsHashValid(string InputStr, string Hash)
 {
     if (Comparer.Compare(GetHash(InputStr), Hash.Trim().ToUpper()) == 0)
     {
         return(true);
     }
     else
     {
         return(false);
     }
 }
コード例 #3
0
 internal bool removeAttribute(string attrName, bool caseSensitive)
 {
     if (caseSensitive)
     {
         if (this.list.Remove(attrName))
         {
             return(true);
         }
         return(false);
     }
     else
     {
         int index = this.SearchCaseInsensitive(attrName);
         if (index < 0)
         {
             return(false);
         }
         while (index < this.list.Count && strcmp.Compare(attrName, this.list.Keys[index]) == 0)
         {
             this.list.RemoveAt(index);
         }
         return(true);
     }
 }