Skip to content

Instantly share code, notes, and snippets.

@oskar456
Created May 15, 2016 16:55
Show Gist options
  • Select an option

  • Save oskar456/38f101c506fb83e69b14b22993feeb88 to your computer and use it in GitHub Desktop.

Select an option

Save oskar456/38f101c506fb83e69b14b22993feeb88 to your computer and use it in GitHub Desktop.
Recover installation QR codes from Google Authenticator App DB
#!/bin/sh
echo "select original_name, secret, issuer from accounts;" |\
sqlite3 authenticator.sqlite |\
sed -rn 's_^([^|]+)\|([^|]+)\|(.+)$_otpauth://totp/\1?secret=\2\&issuer=\3_p' |\
while read line
do
ttyqr $line
echo $line
echo ""
done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment