SHA1l加密

public static string SHA1Encrypt(string sourceText)
{
SHA1 sha = new SHA1CryptoServiceProvider();
ASCIIEncoding enc = new ASCIIEncoding();
byte[] dataToHash = enc.GetBytes(sourceText);
byte[] dataHashed = sha.ComputeHash(dataToHash);
string hash = BitConverter.ToString(dataHashed).Replace("-", "");
return hash;
}
上一篇:ABAP-2-会计凭证批量数据导入本地ACCESS


下一篇:把Excel的数据导入到数据库