Extract TOTP code from QR code
Most people use Google Authenticator as MFA. However if the phone is somehow inaccessible, you might get locked. There are some ways to recover account, and this TOTP tool provide yet another way by simulate what your phone app does.
You should have your QR code saved as a png image.
docker run --rm -v "$(pwd)/example.png:/app/qrcode.png:ro" $(docker build -q https://github.com/shadow-paw/totp.git) /app/qrcode.png
Assume
example.pngis your QR code image located on current directory.
Loading QR code from: /app/qrcode.png
url : /example.com:username
issuer: example.com
code : 123456