News for hackers. Stuff that matters.
Re:How to Live Without Google: Alternatives That Protect You... by tzs on Saturday March 11, 2023 @04:27PM (#35112884)
Authenticator can be backed up locally by using the same mechanism they use for migrating to a new device.

That mechanism gives you a QR code containing the account information for one or more accounts, which you scan on the new device in Authenticator to import those accounts. Repeat until all accounts are migrated. I'm not sure how many accounts they can put in one QR code (I've only used Authenticator briefly to help someone else figure something out, and only put in 4 codes), but I'd expect at least 20.

To make a local backup just use the migration mechanism but instead of scanning the QR codes on a new device save them somewhere. On Apple devices you should be able to simply screenshot the migration QR codes. I've heard that on Android Authenticator blocks screenshots.

The contents of the QR codes are base64 encoded Google protocol buffers. If you extract the contents of the QR code, you can use the command line tool otpauth [1] to extract the TOTP setup URLs for each of the sites in the Google migration code.

You can have otpauth turn those individual site setup URLs into QR code images. This will do the trick:

  otpauth -qr --link <text_from_google_QR_code>
That will leave one PNG file per account, named after the account, in the current directory. You can use those PNG files to setup those accounts on any other TOTP app that can scan QR codes.

[1] https://github.com/dim13/otpauth

There are no comments on this comment yet.