Class AdminPasswordHasher
- Namespace
- Kentico.Membership
- Assembly
- Kentico.Membership.dll
Provides methods for hashing passwords.
public sealed class AdminPasswordHasher
- Inheritance
-
objectAdminPasswordHasher
- Extension Methods
Constructors
AdminPasswordHasher()
Initializes a new instance of AdminPasswordHasher.
public AdminPasswordHasher()
Methods
HashPassword(AdminApplicationUser, string)
Returns a hashed representation of the supplied password
for the specified user
.
public string HashPassword(AdminApplicationUser user, string password)
Parameters
user
AdminApplicationUserThe user whose password is to be hashed.
password
stringThe password to hash.
Returns
- string
A hashed representation of the supplied
password
for the specifieduser
.
Exceptions
- ArgumentNullException
user
VerifyHashedPassword(AdminApplicationUser, string, string)
Returns a Microsoft.AspNetCore.Identity.PasswordVerificationResult indicating the result of a password hash comparison.
public PasswordVerificationResult VerifyHashedPassword(AdminApplicationUser user, string hashedPassword, string providedPassword)
Parameters
user
AdminApplicationUserThe user whose password should be verified.
hashedPassword
stringThe hash value for a user's stored password.
providedPassword
stringThe password supplied for comparison.
Returns
- PasswordVerificationResult
A Microsoft.AspNetCore.Identity.PasswordVerificationResult indicating the result of a password hash comparison.
See Also
IPasswordHasher<TUser>