Skip to content
This repository has been archived by the owner on May 30, 2022. It is now read-only.

AUTHY-WITH-QR-CODE #147

Closed
thisaliahmad opened this issue Sep 4, 2020 · 9 comments
Closed

AUTHY-WITH-QR-CODE #147

thisaliahmad opened this issue Sep 4, 2020 · 9 comments
Assignees

Comments

@thisaliahmad
Copy link

I am working on authy-devise with the user, and active admin both, I want the user to on two-factor authentication with QR code. it's showing my error undefined qr_code when I enter config.authy_enable_qr_code = true in devise.rb. and how i will get QR code in html on my custom view. help needed!

@philnash
Copy link
Contributor

philnash commented Sep 4, 2020

Have you enabled Generic authenticator tokens in your Authy Application settings in the Twilio console? What version of authy-devise are you using?

In a custom view you should have access to a @authy_qr_code instance variable that contains the URL to a QR code image.

@thisaliahmad
Copy link
Author

yes, my QR is enabled on Twilio! am using devise-authy (2.2.0) gem and when I use @authy_qr_code its show me the error of undefined, as config.authy_enable_qr_code = true in devise.rb also generates Error.

@philnash
Copy link
Contributor

philnash commented Sep 7, 2020

What is the error that you see generated when you enable config.authy_enable_qr_code = true? Can you paste the stack trace here, please?

@philnash
Copy link
Contributor

philnash commented Sep 8, 2020

I just created an ActiveAdmin application with DeviseAuthy and turned QR codes on in devise.rb and it worked for me.

I was seeing errors when I did not have Generic authenticator tokens enabled for my Authy application.

Can you double check that for the Authy application that you are working with (that you have the API key for) that Generic authenticator tokens are enabled in the settings. Note: once you flip the switch in the settings, you need to save the application, otherwise it won't be saved.

@philnash philnash self-assigned this Sep 8, 2020
@thisaliahmad
Copy link
Author

if you upload your application where you integrate authy with active admin it will be great help for me to learn it.

@thisaliahmad
Copy link
Author

thisaliahmad commented Sep 8, 2020

I have saved country code and phone numbers in my database, I applied two-factor-authentication from them, for that, I over-ride the POST_enable_authy method with superclass Devise::DeviseAuthyController (custom authy controller) for both admin_users and users now am getting the error of superclass mismatch any solution for this?

@philnash
Copy link
Contributor

philnash commented Sep 9, 2020

Can you post the full stack trace please? I will try to reproduce.

@philnash
Copy link
Contributor

Hey @thisaliahmad, can you share the stack trace so I can see what's going on here? Thanks!

@philnash
Copy link
Contributor

I'm going to close this issue, but if you're still having issues, please re-open it with more details.

Thanks!

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants