Class BcryptPasswordHasher
Password hasher using BCrypt (recommended for production).
Backward-compatible: can verify legacy SHA256+salt hashes from .
New passwords are always hashed with BCrypt.
public class BcryptPasswordHasher : IPasswordHasher
Inheritance
Implements
Methods
NeedsRehash(string)
Checks whether the stored hash is in legacy SHA256 format and needs rehashing to BCrypt.
public static bool NeedsRehash(string hashedPassword)
VerifyPassword(string, string)
Verify a password against a hash.
public bool VerifyPassword(string password, string hashedPassword)
Constructors
BcryptPasswordHasher(int)
Creates a BCrypt password hasher.