Method HeldUnder
- Namespace
- MailFathom.Application.Access.Credentials
- Assembly
- MailFathom.Application.dll
HeldUnder(ScopedGrant)
Reports what a request this credential admits holds under its user's current grant.
public IReadOnlyList<MailFathomPermission> HeldUnder(ScopedGrant userGrant)
Parameters
userGrantScopedGrantWhat the credential's user holds.
Returns
- IReadOnlyList<MailFathomPermission>
The permissions both the user holds and the credential keeps, of each half an endpoint it is presented on reads, in the published order.
Remarks
The same intersection a request is answered with, before a token's scopes narrow it further: the user's grant kept to the half each surface reads and then to the credential's names. The user-facing half counts where the credential is presented on the MCP or the client endpoint and the administrative half where it is presented on the administrative one, so a credential that administers is reported holding what it administers with. A listed name the user does not hold yields nothing, which is why an operator is shown both this and Permissions rather than either alone.
Exceptions
- ArgumentNullException
Thrown when
userGrantis null.