Hi
I need 'I trust this device. Don't ask code for next time' option at the login time using c# code. Every time we our clients used to enter the OTP at the login time. They want this option if they check this checkbox and login they will not ask for OTP again on that device. Please any suggestions or solutions for this uding c# code. Please see the SNIP below as sample i need like this


Amit MohantyPosted Aug 28, 2023, 10:38 AM
Example:
Cr BhargaviPosted Aug 28, 2023, 8:50 AM
rontend Changes: Modify your login form to include a "Remember Me" or "Trust this device" checkbox. When the user checks this box, you'll set a persistent cookie on the user's device.
Backend Changes: When the user logs in and selects the "Remember Me" option, the backend should generate a unique token associated with the user's device and save it in the database along with the user's ID.
Authentication Flow: During subsequent login attempts, the backend should first check for the presence of the persistent cookie on the user's device. If the cookie is found, it can skip the OTP step and log the user in directly.
Security Considerations:
Mohammad HussainPosted Aug 28, 2023, 7:14 AM