Class AdmittedUserCredential
- Namespace
- MailFathom.Application.Access.Credentials
- Assembly
- MailFathom.Application.dll
What judging a user-facing credential establishes, whichever method was judged.
public sealed record AdmittedUserCredential : IEquatable<AdmittedUserCredential>
- Inheritance
-
AdmittedUserCredential
- Implements
- Inherited Members
Remarks
The four facts are one shape because they are established together and travel together: a credential resolves a user, the narrowing its caller is kept to was decided when the credential was provisioned, and which endpoints the user is served on is read in the same statement. Four methods producing four shapes of the same answer would be four places for one of them to be dropped on the way to the principal.
What is deliberately absent is the lookup. A username, a key digest, a fingerprint, and a subject are each what the caller presented, and nothing downstream of authentication has any use for one — so a claim, a log line, and an audit record name the identifier instead.
Constructors
- AdmittedUserCredential(Guid, UserId, IReadOnlyList<MailFathomPermission>, UserEndpointAccess)
What judging a user-facing credential establishes, whichever method was judged.
Properties
- CredentialId
The credential that matched, which is what an audit record and a diagnostic correlate on.
- EndpointAccess
Which endpoints the user may be served on, as read when the credential or the session was resolved, which the surface judging the request asks of its own switch.
- Permissions
The names the request is kept to, in the published order, which narrow what its user's roles grant rather than granting anything.
- Reach
Gets where the credential may be presented, which the surface judging the request asks of it.
- User
The user the request acts for.
Methods
- For(ResolvedUserCredential)
Describes the credential one resolution admitted, refusing an answer that names nothing.