google / google-authenticator-android

Open source fork of the Google Authenticator Android app
https://play.google.com/store/apps/details?id=com.google.android.apps.authenticator2
Apache License 2.0
1.58k stars 470 forks source link

Opening from other app results in 'key not recognized' error. #102

Open wall-daniel opened 5 years ago

wall-daniel commented 5 years ago

Describe the Bug

Whenever I try to open the google authenticator from another app it shows an error to the user that the key wasn't recognized. The URI I used to open the intent was "otpauth://totp/EXAMPLE:email"

Intended Behavior

What I was hoping to do was provide a button on the login screen to open any authenticator app. This is so it is more convenient to the user.

Actual Behavior

Upon opening the app an error message pops up that says the key was not recognized. If you close the dialog than the user can copy the code, it is just annoying that it always pops up.

Reproducing

Try to open the google authenticator from another app using the otpauth schema.

Screenshots

If applicable, add screenshots to help explain your problem.

Device

Pixel XL 1

Additional Information

The exact code I use to create the intent is: Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse("otpauth://totp/ITmanager.net:" + email + "?issuer=ITmanager.net"));