我正在使用加密服务来验证用户加密的密码 这是我的代码:
if (!string.IsNullOrEmpty(lastPassword))
{
if (!lastPassword.Equals(Utilities.Encryt(oldPassword)))
{
idx = -1;
}
//// in utilities Encryt method
public static string Encryt(string source)
{
CryptoServices hashService = new CryptoServices();
return hashService.Encrypt(source);
}
}
此加密服务第一次运行不正常,第二次给出实际结果,帮助验证加密密码,谢谢