UserManager<TUser>.GenerateTwoFactorTokenAsync(TUser, String) Method

Definition

Gets a two factor authentication token for the specified user.

C#
public virtual System.Threading.Tasks.Task<string> GenerateTwoFactorTokenAsync (TUser user, string tokenProvider);

Parameters

user
TUser

The user the token is for.

tokenProvider
String

The provider which will generate the token.

Returns

The Task that represents result of the asynchronous operation, a two factor authentication token for the user.

Applies to

منتج الإصدارات
ASP.NET Core 1.0, 1.1, 2.0, 2.1, 2.2, 3.0, 3.1, 5.0, 6.0, 7.0, 8.0, 9.0