Table of Contents

Method AuthenticateAsync

Namespace
MailFathom.Infrastructure.Security.ApiKeys
Assembly
MailFathom.Infrastructure.dll

AuthenticateAsync(string?, CancellationToken)

Judges the credential an Authorization header carried.

public Task<UserApiKeyAuthenticationResult> AuthenticateAsync(string? authorizationHeaderValue, CancellationToken cancellationToken)

Parameters

authorizationHeaderValue string

The raw header value, or null when the request carried none.

cancellationToken CancellationToken

Cancels the credential read.

Returns

Task<UserApiKeyAuthenticationResult>

What the request was admitted as, or the reason the credential was refused.