public
static
string
MD5(
string str)
{
byte[] array = Encoding.UTF8. GetBytes(str);
array = new MD5CryptoServiceProvider(). ComputeHash(array);
string text = "";
for ( int i = 0; i < array.Length; i++)
{
text += array[i]. ToString( "x"). PadLeft( 2, '0');
}
return text;
}
{
byte[] array = Encoding.UTF8. GetBytes(str);
array = new MD5CryptoServiceProvider(). ComputeHash(array);
string text = "";
for ( int i = 0; i < array.Length; i++)
{
text += array[i]. ToString( "x"). PadLeft( 2, '0');
}
return text;
}
做一个解密程序.