SignInManager<TUser>.PasswordSignInAsync Method

Definition

Overloads

PasswordSignInAsync(String, String, Boolean, Boolean)

Attempts to sign in the specified userName and password combination as an asynchronous operation.

PasswordSignInAsync(TUser, String, Boolean, Boolean)

Attempts to sign in the specified user and password combination as an asynchronous operation.

PasswordSignInAsync(String, String, Boolean, Boolean)

Source:
SignInManager.cs
Source:
SignInManager.cs

Attempts to sign in the specified userName and password combination as an asynchronous operation.

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Identity::SignInResult ^> ^ PasswordSignInAsync(System::String ^ userName, System::String ^ password, bool isPersistent, bool lockoutOnFailure);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.SignInResult> PasswordSignInAsync (string userName, string password, bool isPersistent, bool lockoutOnFailure);
abstract member PasswordSignInAsync : string * string * bool * bool -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.SignInResult>
override this.PasswordSignInAsync : string * string * bool * bool -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.SignInResult>
Public Overridable Function PasswordSignInAsync (userName As String, password As String, isPersistent As Boolean, lockoutOnFailure As Boolean) As Task(Of SignInResult)

Parameters

userName
String

The user name to sign in.

password
String

The password to attempt to sign in with.

isPersistent
Boolean

Flag indicating whether the sign-in cookie should persist after the browser is closed.

lockoutOnFailure
Boolean

Flag indicating if the user account should be locked if the sign in fails.

Returns

The task object representing the asynchronous operation containing the for the sign-in attempt.

Applies to

PasswordSignInAsync(TUser, String, Boolean, Boolean)

Source:
SignInManager.cs
Source:
SignInManager.cs

Attempts to sign in the specified user and password combination as an asynchronous operation.

public:
 virtual System::Threading::Tasks::Task<Microsoft::AspNetCore::Identity::SignInResult ^> ^ PasswordSignInAsync(TUser user, System::String ^ password, bool isPersistent, bool lockoutOnFailure);
public virtual System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.SignInResult> PasswordSignInAsync (TUser user, string password, bool isPersistent, bool lockoutOnFailure);
abstract member PasswordSignInAsync : 'User * string * bool * bool -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.SignInResult>
override this.PasswordSignInAsync : 'User * string * bool * bool -> System.Threading.Tasks.Task<Microsoft.AspNetCore.Identity.SignInResult>
Public Overridable Function PasswordSignInAsync (user As TUser, password As String, isPersistent As Boolean, lockoutOnFailure As Boolean) As Task(Of SignInResult)

Parameters

user
TUser

The user to sign in.

password
String

The password to attempt to sign in with.

isPersistent
Boolean

Flag indicating whether the sign-in cookie should persist after the browser is closed.

lockoutOnFailure
Boolean

Flag indicating if the user account should be locked if the sign in fails.

Returns

The task object representing the asynchronous operation containing the for the sign-in attempt.

Applies to