C#怎么用MD5加密
C#我记得带个函数,进行MD5加密的,哪位大哥告诉我怎么用?顺便告诉我怎么给别人加分.万分感谢.Q536823,加Q教我也行..
------解决方案--------------------System.Web.Security.FormsAuthentication.HashPasswordForStoringInConfigFile(txtPassWord.Text, "MD5 ");
------解决方案--------------------直接给你源代码,说多了怕你理解不清爽 :)
function TForm_SetWebSuPassword.GetMd5String(strIn: string): string;
var
MyMD5:MD5CryptoServiceProvider;
begin
MyMD5:=MD5CryptoServiceProvider.Create();
result:=BitConverter.ToString(MyMD5.ComputeHash(Encoding.Default.GetBytes(strIn))).Replace( '- ', ' ').ToLower();
end;