AuthenticationHttpContextExtensions.SignInAsync Method

Definition

Overloads

SignInAsync(HttpContext, ClaimsPrincipal)

Sign in a principal for the default authentication scheme. The default scheme for signing in can be configured using DefaultSignInScheme.

SignInAsync(HttpContext, ClaimsPrincipal, AuthenticationProperties)

Sign in a principal for the default authentication scheme. The default scheme for signing in can be configured using DefaultSignInScheme.

SignInAsync(HttpContext, String, ClaimsPrincipal)

Sign in a principal for the specified scheme.

SignInAsync(HttpContext, String, ClaimsPrincipal, AuthenticationProperties)

Sign in a principal for the specified scheme.

SignInAsync(HttpContext, ClaimsPrincipal)

Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs

Sign in a principal for the default authentication scheme. The default scheme for signing in can be configured using DefaultSignInScheme.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task ^ SignInAsync(Microsoft::AspNetCore::Http::HttpContext ^ context, System::Security::Claims::ClaimsPrincipal ^ principal);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, System.Security.Claims.ClaimsPrincipal principal);
static member SignInAsync : Microsoft.AspNetCore.Http.HttpContext * System.Security.Claims.ClaimsPrincipal -> System.Threading.Tasks.Task
<Extension()>
Public Function SignInAsync (context As HttpContext, principal As ClaimsPrincipal) As Task

Parameters

context
HttpContext

The HttpContext context.

principal
ClaimsPrincipal

The user.

Returns

The task.

Applies to

SignInAsync(HttpContext, ClaimsPrincipal, AuthenticationProperties)

Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs

Sign in a principal for the default authentication scheme. The default scheme for signing in can be configured using DefaultSignInScheme.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task ^ SignInAsync(Microsoft::AspNetCore::Http::HttpContext ^ context, System::Security::Claims::ClaimsPrincipal ^ principal, Microsoft::AspNetCore::Authentication::AuthenticationProperties ^ properties);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, System.Security.Claims.ClaimsPrincipal principal, Microsoft.AspNetCore.Authentication.AuthenticationProperties properties);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, System.Security.Claims.ClaimsPrincipal principal, Microsoft.AspNetCore.Authentication.AuthenticationProperties? properties);
static member SignInAsync : Microsoft.AspNetCore.Http.HttpContext * System.Security.Claims.ClaimsPrincipal * Microsoft.AspNetCore.Authentication.AuthenticationProperties -> System.Threading.Tasks.Task
<Extension()>
Public Function SignInAsync (context As HttpContext, principal As ClaimsPrincipal, properties As AuthenticationProperties) As Task

Parameters

context
HttpContext

The HttpContext context.

principal
ClaimsPrincipal

The user.

Returns

The task.

Applies to

SignInAsync(HttpContext, String, ClaimsPrincipal)

Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs

Sign in a principal for the specified scheme.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task ^ SignInAsync(Microsoft::AspNetCore::Http::HttpContext ^ context, System::String ^ scheme, System::Security::Claims::ClaimsPrincipal ^ principal);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, string scheme, System.Security.Claims.ClaimsPrincipal principal);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, string? scheme, System.Security.Claims.ClaimsPrincipal principal);
static member SignInAsync : Microsoft.AspNetCore.Http.HttpContext * string * System.Security.Claims.ClaimsPrincipal -> System.Threading.Tasks.Task
<Extension()>
Public Function SignInAsync (context As HttpContext, scheme As String, principal As ClaimsPrincipal) As Task

Parameters

context
HttpContext

The HttpContext context.

scheme
String

The name of the authentication scheme.

principal
ClaimsPrincipal

The user.

Returns

The task.

Applies to

SignInAsync(HttpContext, String, ClaimsPrincipal, AuthenticationProperties)

Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs
Source:
AuthenticationHttpContextExtensions.cs

Sign in a principal for the specified scheme.

public:
[System::Runtime::CompilerServices::Extension]
 static System::Threading::Tasks::Task ^ SignInAsync(Microsoft::AspNetCore::Http::HttpContext ^ context, System::String ^ scheme, System::Security::Claims::ClaimsPrincipal ^ principal, Microsoft::AspNetCore::Authentication::AuthenticationProperties ^ properties);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, string scheme, System.Security.Claims.ClaimsPrincipal principal, Microsoft.AspNetCore.Authentication.AuthenticationProperties properties);
public static System.Threading.Tasks.Task SignInAsync (this Microsoft.AspNetCore.Http.HttpContext context, string? scheme, System.Security.Claims.ClaimsPrincipal principal, Microsoft.AspNetCore.Authentication.AuthenticationProperties? properties);
static member SignInAsync : Microsoft.AspNetCore.Http.HttpContext * string * System.Security.Claims.ClaimsPrincipal * Microsoft.AspNetCore.Authentication.AuthenticationProperties -> System.Threading.Tasks.Task
<Extension()>
Public Function SignInAsync (context As HttpContext, scheme As String, principal As ClaimsPrincipal, properties As AuthenticationProperties) As Task

Parameters

context
HttpContext

The HttpContext context.

scheme
String

The name of the authentication scheme.

principal
ClaimsPrincipal

The user.

Returns

The task.

Applies to