天津市南开区供暖交费:asp.net(c#)中,md5加密代码

来源:百度文库 编辑:查人人中国名人网 时间:2024/04/30 02:47:45
asp.net(c#)中,md5加密代码
还有用法

string strMd5 = System.Web.Security.FormsAuthentication.HashPasswordForStoringInConfigFile("123", "md5");

strMd5 就是 123 经过 MD5 加密后的结果

[C#]
using System.Security.Cryptography;

byte[] data = new byte[DATA_SIZE];

// This is one implementation of the abstract class MD5.
MD5 md5 = new MD5CryptoServiceProvider();

byte[] result = md5.ComputeHash(data);