IAuthenticationSchemeHandler
Members
Namespace: ASPSecurityKit.AuthProviders
Assembly: ASPSecurityKit.dll
Summary
Provides an interface to implement support for a scheme to authenticate requests by the security pipeline. To learn more, visit https://ASPSecurityKit.net/docs/the-security-pipeline/#authentication
Methods
Validate(requestService)
Summary
Evaluates the specified request against the auth scheme represented by this interface.
Returns
AuthSchemeValidationResult instance with Evaluated as true
If the scheme was found in the request (along with either Auth as not null if evaluation succeeded or Error populated if it failed); otherwise, false
.
Parameters
Name | Type | Description |
---|---|---|
requestService | ASPSecurityKit.IRequestService | The request service. |
Exceptions
Type | Description |
---|---|
System.ArgumentNullException | When requestService is null. |
ValidateAsync(requestService)
Summary
Evaluates the specified request against the auth scheme represented by this interface.
Returns
AuthSchemeValidationResult instance with Evaluated as true
If the scheme was found in the request (along with either Auth as not null if evaluation succeeded or Error populated if it failed); otherwise, false
.
Parameters
Name | Type | Description |
---|---|---|
requestService | ASPSecurityKit.IRequestService | The request service. |
Exceptions
Type | Description |
---|---|
System.ArgumentNullException | When requestService is null. |
ValidateAsync(requestService,cancellationToken)
Summary
Evaluates the specified request against the auth scheme represented by this interface.
Returns
AuthSchemeValidationResult instance with Evaluated as true
If the scheme was found in the request (along with either Auth as not null if evaluation succeeded or Error populated if it failed); otherwise, false
.
Parameters
Name | Type | Description |
---|---|---|
requestService | ASPSecurityKit.IRequestService | The request service. |
cancellationToken | System.Threading.CancellationToken | The cancellation token. |
Exceptions
Type | Description |
---|---|
System.ArgumentNullException | When requestService is null. |