45
Views
3
Comments
Solved
[TwoFactorAuthenticator] Getting error only in production environment on TOTP Validate
Question
twofactorauthenticator
Service icon
Forge asset by Babu Basha
Application Type
Service

Hi Everyone,

I've implemented the two factor authenticator in my customer  environment and it works fine in both development and test environments (which use UTC time), but when the application is published to production environment we face an error "INVALID OTP". 

I'll attach an image to better explain the issue (the OML file is basically identical to the orginal demo available in the forge).

Basically the error occurs when the customer clicks on the 'Confirm OTP' button.

When the button is clicked the "Verify and Confirm OTP" runs and inside it the 'TOTP Validate' action is executed.

Here is where the error occurs, the error is "INVALID OTP".

Unfortunately I can not run the debbuger in production environment but I do know that here is where the error occurs.

I don't know if this could be related or not, but the production environment use CET time (not UTC like dev and test environments). 

Got any suggestions?

Cheers,

Gianmaria



2FA_Issue.png
2019-10-24 08-26-27
Babu Basha
Solution


Hello Gianmaria bellucci,

Could you please send UTC datetime here instead of CurrDateTime() which happens to be different timezone. Please add a fix on your end, I will publish a newer version of this component soon. 


Thanks,

Babu


UserImage.jpg
Gianmaria Bellucci

Hello @Babu Basha,

thanks for your feedback. I'll change it asap and confirms if it works.


Cheers,

Gianmaria

UserImage.jpg
Gianmaria Bellucci

Thanks @Babu Basha ,

I've done as you suggested and it did work perfectly.

Kind regards,

Gianmaria

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.