Not able to Enable and Verfiy TOTP based MFA token using Cognito

0

Hi, I was trying to write a React code for enabling TOTP based MFA for an user in cognito userpool. but i am not able to enable it. as i tried different code these is the error i am getting .

**Reason: { message: "Code mismatch", code: "EnableSoftwareTokenMFAException", time: "2022-05-04T12:53:02.136Z",… } error: "EnableSoftwareTokenMFAException: Code mismatch" success: false **

i tried google authenticator and microsoft authenticator but still the same error message. sometimes code works but most of the time i am getting this error.

how to resolve this ? what may be the reason for this error ?

here's the link to my codebase i been refering : https://github.com/AlexzanderFlores/Worn-Off-Keys-Cognito-Tutorials/blob/master/10-TOTP-MFA/lambda/get-qr-code/index.js

Keine Antworten

Du bist nicht angemeldet. Anmelden um eine Antwort zu veröffentlichen.

Eine gute Antwort beantwortet die Frage klar, gibt konstruktives Feedback und fördert die berufliche Weiterentwicklung des Fragenstellers.

Richtlinien für die Beantwortung von Fragen