You can try DEMO, the password is 123.
Since Authy discontinued their desktop application I was struggling to find a replacement.
Everything I tried is bulky and overcomplicated.
I decided to make my own.
It's a simple password-protected page where you can see all your 2FA codes updating in real time.
Click to copy the code.
Start typing to filter codes.
I tried to make it as secure as possible.
But,
- I am no security expert.
- I am no python or web expert.
So you must consider this project as insecure.
OTP secrets are stored encrypted in yaml file. They are encrypted by Fernet
Whenever you input the right password on the frontend, OTP keys are decrypted and stored on the server side. You are getting a new page with a short living token that is used to establish WebSocket connection. The server sends you the OTP values (secrets are never exposed) every time they are updated.
When the WebSocket connection is shut down (like you closed the tab, refreshed the page or you hit the 5 minute treshold) the decrypted secrets are erased from the memory of the server.
The short living token used to establish a WebSocket connection lives just 10 seconds and allows to create only a single connection.
The security is achived by not exposing any secrets to the client and server has it unencrypted only during the session.
There is also a rate limiter on the password check.
- clone the project
- Hash your password using Bcrypt algorithm
- Create
.envfile like.env_example - Put the hash in the
PREDEFINED_HASHvariable in the.envfile - run
docker compose up -d - run
docker compose exec app python3 main.py --add-secretto add a secret. Make sure that you use base32 secret, but it is pretty much standard, so I believe in you! Also, your password must match the one you used forPREDEFINED_HASH - Open
http://localhost:11211and enter your password. You will see your OTP codes.
Run docker compose exec app python3 main.py --remove-secret to remove a secret.
docker-compose.yml is set up to listen only localhost. It's HIGHLY recommended to put it behind the reverse proxy.
I recommend Caddy since it has HTTPS support out of the box.
NEVER USE THIS TOOL WITHOUT HTTPS
The tool supports most common algorithms but only 30 seconds based TOTPs.
The configuration available:
| Env variable | Description | Optionality |
|---|---|---|
PREDEFINED_HASH |
Bcrypt hash which represents your password to access the codes | ❌ |
URL_PREFIX |
To host it somewhere like www.example.com/my_totp | ✅ |
HOST_IP |
To listen a different IP in docker-compose.yml, if for example you use Wireguard |
✅ |
The hard part is exporting your keys from Authy or other services. You should google how to do it with your current setup.
Most good tools support export, but Authy or Google Authenticator requires some effort.