two_factor_authentication
two_factor_authentication copied to clipboard
User is directly getting access to site without asking for code
I am using rails 5.2 and two_factor_authentication 2.1.1. I am following exact steps mentioned in https://github.com/Houdini/two_factor_authentication/blob/master/README.md and https://www.rubydoc.info/gems/two_factor_authentication/1.1.5. When user signs in it get direct access to site without asking for code. It worked once and all of a sudden stopped working.
I am having the same issue here, it worked in the first time but never again
Currently its working for me I added create_direct_otp method to my user model and made this true config.delete_cookie_on_logout = true in devise.rb file.
But if you just make config.delete_cookie_on_logout = false this true and don't add create method to user model it does not work.
The config.delete_cookie_on_logout = true was enough for me, thanks for the help, it's working now
+1 config.delete_cookie_on_logout = true -- That's all you need to do.