Interface IAuthenticationHandler
Represents authentication handler for command-line AMI.
Namespace: DotNext.Maintenance.CommandLine.Authentication
Assembly: DotNext.MaintenanceServices.dll
Syntax
public interface IAuthenticationHandler
Methods
| Edit this page View SourceChallengeAsync(ParseResult, IIdentity, CancellationToken)
Challenges the maintenance session.
Declaration
ValueTask<IPrincipal?> ChallengeAsync(ParseResult result, IIdentity identity, CancellationToken token)
Parameters
| Type | Name | Description |
|---|---|---|
| ParseResult | result | The parsing result. |
| IIdentity | identity | The identity of the user to authenticate. |
| CancellationToken | token | The token that can be used to cancel the operation. |
Returns
| Type | Description |
|---|---|
| ValueTask<IPrincipal> | Authentication result; or null in case of failed authentication. |
GetGlobalOptions()
Gets global options that can be used to authenticate the command.
Declaration
IEnumerable<Option> GetGlobalOptions()
Returns
| Type | Description |
|---|---|
| IEnumerable<Option> | A collection of global options. |