ResultContext<TOptions> Class

Definition

Base context for events that produce AuthenticateResults.

C#
public abstract class ResultContext<TOptions> : Microsoft.AspNetCore.Authentication.BaseContext<TOptions> where TOptions : AuthenticationSchemeOptions

Type Parameters

TOptions
Inheritance
ResultContext<TOptions>
Derived

Constructors

Properties

HttpContext

The context.

(Inherited from BaseContext<TOptions>)
Options

Gets the authentication options associated with the scheme.

(Inherited from BaseContext<TOptions>)
Principal

Gets or sets the ClaimsPrincipal containing the user claims.

Properties

Gets or sets the AuthenticationProperties.

Request

The request.

(Inherited from BaseContext<TOptions>)
Response

The response.

(Inherited from BaseContext<TOptions>)
Result

Gets the AuthenticateResult result.

Scheme

The authentication scheme.

(Inherited from BaseContext<TOptions>)

Methods

Fail(Exception)

Indicates that there was a failure during authentication.

Fail(String)

Indicates that there was a failure during authentication.

NoResult()

Indicates that there was no information returned for this authentication scheme.

Success()

Calls success creating a ticket with the Principal and Properties.

Applies to

Product Versions
ASP.NET Core 2.0, 2.1, 2.2, 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0