Source/NFX/MiscUtils.cs
/// <summary>
/// Returns a MD5 hash of a UTF8 string represented as hex string
/// </summary>
Returns a MD5 hash of a UTF8 string represented as hex string
Returns a MD5 hash of a UTF8 string represented as hex string
public static string ToMD5String(this byte[] input)
    {
      if (input==null)
       return "00000000000000000000000000000000";
      using (var md5 = new System.Security.Cryptography.MD5CryptoServiceProvider())
      {
         var hash = md5.ComputeHash(input);
         var result = new StringBuilder();
         for(var i=0;i<hash.Length;i++)
          result.Append(hash[i].ToString("x2"));
         return result.ToString();
      }
    }
public static string ToMD5String ( this byte [ ] input ) { if ( input == null ) return " " ; using ( var md5 = new System . Security . Cryptography . MD5CryptoServiceProvider ( ) ) { var hash = md5 . ComputeHash ( input ) ; var result = new StringBuilder ( ) ; for ( var i = 0 ; i < hash . Length ; i ++ ) result . Append ( hash [ i ] . ToString ( " " ) ) ; return result . ToString ( ) ; } }
Returns a MD5 hash of a UTF8 string represented as hex string
Returns a MD5 hash of a UTF8 string represented as hex string
byte[]
this