GenerateTwoFactorTokenAsync custom expiry time for OTP code

Sandeep Mishra 1 Reputation point
2022-03-16T11:37:59.03+00:00

I am using below code for 2FA but i wanted to increas time limit of 2 FA code.

Can anyone help me on this

var code = await _userManager.GenerateTwoFactorTokenAsync(user, TokenOptions.DefaultEmailProvider);

Microsoft Authenticator
Microsoft Authenticator
A Microsoft app for iOS and Android devices that enables authentication with two-factor verification, phone sign-in, and code generation.
5,690 questions
0 comments No comments
{count} votes