UserManager<TUser, TKey>.CheckPasswordAsync Method (TUser, String)

 

Determines whether the password is valid for the user.

Namespace:   Microsoft.AspNet.Identity
Assembly:  Microsoft.AspNet.Identity.Core (in Microsoft.AspNet.Identity.Core.dll)

Syntax

public virtual Task<bool> CheckPasswordAsync(
    TUser user,
    string password
)
public:
virtual Task<bool>^ CheckPasswordAsync(
    TUser user,
    String^ password
)
abstract CheckPasswordAsync : 
        user:'TUser *
        password:string -> Task<bool>
override CheckPasswordAsync : 
        user:'TUser *
        password:string -> Task<bool>
Public Overridable Function CheckPasswordAsync (
    user As TUser,
    password As String
) As Task(Of Boolean)

Parameters

  • user
    Type: TUser

    The user.

Return Value

Type: System.Threading.Tasks.Task<Boolean>

The task representing the asynchronous operation that returns true if the password is valid for the user; otherwise, false.

See Also

UserManager<TUser, TKey> Class
Microsoft.AspNet.Identity Namespace
ASP.NET Identity

Return to top