Constructor UserPasswordAuthenticator
- Namespace
- MailFathom.Infrastructure.Security.Passwords
- Assembly
- MailFathom.Infrastructure.dll
UserPasswordAuthenticator(IUserCredentialStore, IPasswordHasher, PasswordAttemptLimiter, DecoyPasswordHash, ILogger<UserPasswordAuthenticator>)
Initializes a new user password authenticator.
public UserPasswordAuthenticator(IUserCredentialStore credentials, IPasswordHasher passwordHasher, PasswordAttemptLimiter attemptLimiter, DecoyPasswordHash decoy, ILogger<UserPasswordAuthenticator> logger)
Parameters
credentialsIUserCredentialStoreWhere the users' credentials are kept.
passwordHasherIPasswordHasherWhat a presented password is judged with, and what a record behind the policy is rewritten by.
attemptLimiterPasswordAttemptLimiterThe bound on how often a source or a username may have a password checked.
decoyDecoyPasswordHashThe record an unresolved username is compared against, derived once for the process.
loggerILogger<UserPasswordAuthenticator>The log a refusal and a rehash failure are recorded in.
Remarks
Nothing is derived here, so constructing this per request costs what resolving four services costs.
Exceptions
- ArgumentNullException
Thrown when any argument but the logger is null.