mã hóa SHA1 trong lập trình c

1 627 0
mã hóa SHA1 trong lập trình c

Đang tải... (xem toàn văn)

Thông tin tài liệu

public static string EncryptPassword(string Password) { System.Text.UnicodeEncoding encoding = new System.Text.UnicodeEncoding(); byte[] hashBytes = encoding.GetBytes(Password); //Compute the SHA-1 hash SHA1CryptoServiceProvider sha1 = new SHA1CryptoServiceProvider(); byte[] cryptPassword = sha1.ComputeHash(hashBytes); return BitConverter.ToString(cryptPassword); }

Ngày đăng: 22/08/2016, 16:39

Tài liệu cùng người dùng

  • Đang cập nhật ...

Tài liệu liên quan