Method Authenticated
- Namespace
- MailFathom.Infrastructure.Security.Passwords
- Assembly
- MailFathom.Infrastructure.dll
Authenticated(Guid, UserId, IReadOnlyList<MailFathomPermission>, UserEndpointAccess, UserCredentialReach)
Creates a successful result naming the credential that matched and what it admits.
public static UserPasswordAuthenticationResult Authenticated(Guid authenticatedCredentialId, UserId user, IReadOnlyList<MailFathomPermission> permissions, UserEndpointAccess endpointAccess, UserCredentialReach reach)
Parameters
authenticatedCredentialIdGuidThe identifier of the matching credential.
userUserIdThe user the request acts for.
permissionsIReadOnlyList<MailFathomPermission>What the request may do.
endpointAccessUserEndpointAccessWhich endpoints the user may be served on, read beside the credential.
reachUserCredentialReachWhere the credential may be presented.
Returns
- UserPasswordAuthenticationResult
The successful result.
Exceptions
- ArgumentNullException
Thrown when
permissionsorreachis null.- ArgumentException
Thrown when the identifier is empty or
usernames nobody.