今天做一个求字符串MD5加密的小程序,新建了一个C#控制台应用程序,输入下面代码using System;using System.Collections.Generic;using System.Text;using System.Web;namespace 求md5{ class Program { static void Main(string[] args) { string str = GetMd5("xuwei"); Console.WriteLine(str); } public static string GetMd5(string str)//求MD5 { return System.Web.Security.FormsAuthentication.HashPasswordForStoringInConfigFile(str, "MD5").ToLower().Substring(8,16); } }}using S 你的当前访问异常,请进行认证后继续阅读剩余内容。 提交