Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zebradil/rustotpony
🐴 RusTOTPony — CLI manager of one-time password generators aka Google Authenticator
https://github.com/zebradil/rustotpony
cli otp otpa rust totp
Last synced: 26 days ago
JSON representation
🐴 RusTOTPony — CLI manager of one-time password generators aka Google Authenticator
- Host: GitHub
- URL: https://github.com/zebradil/rustotpony
- Owner: Zebradil
- License: mit
- Created: 2018-01-01T18:59:34.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2024-10-19T19:12:04.000Z (about 2 months ago)
- Last Synced: 2024-10-20T07:18:39.180Z (about 2 months ago)
- Topics: cli, otp, otpa, rust, totp
- Language: Rust
- Homepage:
- Size: 277 KB
- Stars: 30
- Watchers: 5
- Forks: 3
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
- Funding: .github/FUNDING.yml
- License: LICENSE
Awesome Lists containing this project
- awesome-rust-cn - zebradil/rustotpony - time password generators aka Google Authenticator (TOTP) (Libraries / Cryptography)
- awesome-rust - zebradil/rustotpony - time password generators aka Google Authenticator (TOTP) (Libraries / Cryptography)
- awesome-rust-zh - zebradil/rustotpony - 一次性密码生成器的 CLI 管理器,即 Google Authenticator(TOTP) (库 / 加密)
- awesome-rust - zebradil/rustotpony - time password generators aka Google Authenticator (TOTP) (库 Libraries / 密码学 Cryptography)
README
# 🐴 RusTOTPony
![crates.io](https://img.shields.io/crates/v/rustotpony.svg)
![build](https://github.com/zebradil/rustotpony/workflows/build/badge.svg)CLI manager of [time-based one-time password](https://en.wikipedia.org/wiki/Time-based_One-time_Password_algorithm) generators.
It is a desktop alternative to Google Authenticator.## Installation
### Arch Linux
Packages, available in [AUR](https://aur.archlinux.org/):
- [rustotpony](https://aur.archlinux.org/packages/rustotpony/)
- [rustotpony-bin](https://aur.archlinux.org/packages/rustotpony-bin/)### Other
Grab an appropriate binary from [the latest release](https://github.com/Zebradil/rustotpony/releases/latest) and put it
in a place of your choice. If you're on the \*nix system, don't forget to set proper permissions: `chmod +x totp`.### Build manually
#### From crates.io
Make sure you have `$HOME/.cargo/bin` in your `$PATH`.
```shell
cargo install rustotpony
```#### From source
1. Clone this repo
1. Run `cargo install` from the inside of the repo directory
1. Keep calm and wait for the compilationProbably, you will need `gcc` (Linux) or `clang` (Mac OS) to compile dependencies.
## Usage
```text
$ totp help
🐴 RusTOTPony 0.3.2Manager of one-time password generators
Usage: totp [COMMAND]
Commands:
dash Show realtime dashboard with all generators
list List all generators
add Add a new generator
delete Delete a generator
rename Rename a generator
eradicate Delete all generators
help Print this message or the help of the given subcommand(s)Options:
-h, --help Print help information
-V, --version Print version information
```### Choose your password wisely
On the first run, `totp` will prompt you to create a password for a new database, which is stored at `$HOME/.rustotpony/totp.safe`.
This database is encrypted using the password you provide with age-encryption.If you forget the password or wish to change it, you will need to delete the database file.
While this process is currently a bit inconvenient,
I'm working on improving usability and will be adding a command to facilitate password changes in the future.### Basic scenario
1. Retrieve a secret key from your TOTP provider (it must be encoded with base32, for example, `GEZDGMZSGE2TKCQ=`)
```shell
$ # Creating a fake secret key for demo purposes
$ echo 123321555 | base32
GEZDGMZSGE2TKNIK
```1. Add new generator with `totp add ` (you will be asked for a secret and a password)
```shell
$ # Adding a new TOTP generator
$ totp add demo
Enter your secret code:
Enter your database pass:
New application created: demo
```1. Use `totp list` to check your secrets
```shell
$ # Listing all secrets in the database
$ totp list
Enter your database pass:
+------+------------------+----------+
| name | key | username |
+------+------------------+----------+
| demo | GEZDGMZSGE2TKNIK | |
+------+------------------+----------+
```1. Use `totp dash` or just `totp` for real-time dashboard
```shell
$ # Display real-time dashboard with all generators
$ totp
Enter your database pass:
Welcome to RusTOTPony realtime dashboard! Press ^C to quit.
[============================================= ]
009216 demo
```1. After hitting ^C it'll clean up the dashboard
```shell
$ totp
Enter your database pass:
I won't tell anyone about this 🤫
```## TODO
[./TODO.md](./TODO.md)
## License
Licensed under [the MIT License][MIT License].
[MIT License]: https://github.com/zebradil/rustotpony/blob/master/LICENSE