When exporting Authy accounts that have keys that have not been decrypted (because this device silently can't decrypt the newly synced accounts, for some reason, which is driving me to a different app), the exporter crashes with a stack trace.
Expected: warnings for the two broken accounts, and an export of the rest of the accounts.
Workaround: I deleted the accounts from Authy and was then able to export the rest.
The partial accounts look like this. Note that I edited some data for privacy, so the crypto won't line up:
{"accountType":"authenticator","digits":6,"encryptedSecret":"iaRiajhaOfjSRz1a5uKmjm
GDznslSa+eAAS8cfeNG03y49qsjd5XNmYKHbPG1+h+","key_derivation_iterations":100000,"lastLogoVerificationTime":1741537259123,"
;logo":"website.com","originalIssuer":"website.com","originalName":"redacteduser","timestamp&qu
ot;:1748137451,"salt":"jK08j9puCa6aTSxsMIahBGJnrzV72CtW","upload_state":"uploaded","hidden":false,&q
uot;id":"1713538131","isNew":false,"name":"Website - redacteduser"}
python -m android_otp_extractor -v --include authy
2025-05-29 21:02:28 DESKTOP-U6A5AUE android_otp_extractor.adb[526] INFO Testing if your phone uses binary: 'toybox'
2025-05-29 21:02:28 DESKTOP-U6A5AUE android_otp_extractor.adb[526] INFO Checking if adb already runs as root
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] INFO Attempting to enable adb root
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] INFO Listing contents of / as root
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Listing directory /
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] INFO Reading and hashing contents of build.prop as root
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Hashing file $ANDROID_ROOT/build.prop
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Trying to read file $ANDROID_ROOT/build.prop
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Successfully read 8491 bytes
2025-05-29 21:02:29 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Hashing file $ANDROID_ROOT/build.prop
2025-05-29 21:02:30 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Trying to read file $ANDROID_ROOT/build.prop
2025-05-29 21:02:30 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Successfully read 8491 bytes
2025-05-29 21:02:30 DESKTOP-U6A5AUE android_otp_extractor.adb[526] INFO Using command line utility binary: 'toybox'
2025-05-29 21:02:30 DESKTOP-U6A5AUE android_otp_extractor.apps[526] INFO Reading Authy accounts
2025-05-29 21:02:30 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Trying to read file $ANDROID_DATA/data/com.authy.authy/shared_prefs/com.authy.storage.tokens.authenticator.xml
2025-05-29 21:02:30 DESKTOP-U6A5AUE android_otp_extractor.adb[526] DEBUG Successfully read 27083 bytes
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/home/user/android-otp-extractor/lib/python3.13/site-packages/android_otp_extractor/__main__.py", line 3, in <module>
main()
~~~~^^
File "/home/user/android-otp-extractor/lib/python3.13/site-packages/android_otp_extractor/cli.py", line 62, in main
accounts = apps.read_accounts(adb, enabled_apps)
File "/home/user/android-otp-extractor/lib/python3.13/site-packages/android_otp_extractor/apps.py", line 416, in read_accounts
new = list(app.extractor(adb))
File "/home/user/android-otp-extractor/lib/python3.13/site-packages/android_otp_extractor/apps.py", line 67, in read_authy_accounts
secret = bytes.fromhex(account['secretSeed'])
~~~~~~~^^^^^^^^^^^^^^
KeyError: 'secretSeed'
When exporting Authy accounts that have keys that have not been decrypted (because this device silently can't decrypt the newly synced accounts, for some reason, which is driving me to a different app), the exporter crashes with a stack trace.
Expected: warnings for the two broken accounts, and an export of the rest of the accounts.
Workaround: I deleted the accounts from Authy and was then able to export the rest.
The partial accounts look like this. Note that I edited some data for privacy, so the crypto won't line up: