ServiceAuthenticationFilter.AuthenticateAsync Method

Definition

Overloads

AuthenticateAsync(IAuthenticationManager)

Asynchronously authenticates the current request by looking for an OWIN authentication middleware with the given AuthenticationType and delegating authentication to that middleware.

AuthenticateAsync(HttpAuthenticationContext, CancellationToken)

Asynchronously authenticates the current request by looking for an OWIN authentication middleware with the given AuthenticationType and delegating authentication to that middleware.

AuthenticateAsync(IAuthenticationManager)

Asynchronously authenticates the current request by looking for an OWIN authentication middleware with the given AuthenticationType and delegating authentication to that middleware.

protected virtual System.Threading.Tasks.Task<System.Security.Principal.IPrincipal> AuthenticateAsync (Microsoft.Owin.Security.IAuthenticationManager authenticationManager);
abstract member AuthenticateAsync : Microsoft.Owin.Security.IAuthenticationManager -> System.Threading.Tasks.Task<System.Security.Principal.IPrincipal>
override this.AuthenticateAsync : Microsoft.Owin.Security.IAuthenticationManager -> System.Threading.Tasks.Task<System.Security.Principal.IPrincipal>
Protected Overridable Function AuthenticateAsync (authenticationManager As IAuthenticationManager) As Task(Of IPrincipal)

Parameters

authenticationManager
IAuthenticationManager

The IAuthenticationManager to use for performing the authentication.

Returns

A Task<TResult> representing the authentication operation.

Applies to

AuthenticateAsync(HttpAuthenticationContext, CancellationToken)

Asynchronously authenticates the current request by looking for an OWIN authentication middleware with the given AuthenticationType and delegating authentication to that middleware.

public virtual System.Threading.Tasks.Task AuthenticateAsync (System.Web.Http.Filters.HttpAuthenticationContext context, System.Threading.CancellationToken cancellationToken);
abstract member AuthenticateAsync : System.Web.Http.Filters.HttpAuthenticationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
override this.AuthenticateAsync : System.Web.Http.Filters.HttpAuthenticationContext * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Overridable Function AuthenticateAsync (context As HttpAuthenticationContext, cancellationToken As CancellationToken) As Task

Parameters

context
System.Web.Http.Filters.HttpAuthenticationContext

The authentication context.

cancellationToken
CancellationToken

The cancellation token.

Returns

A Task representing the authentication operation.

Implements

System.Web.Http.Filters.IAuthenticationFilter.AuthenticateAsync(System.Web.Http.Filters.HttpAuthenticationContext,System.Threading.CancellationToken)

Applies to