Skip to main content

Dank One Time Password - CLI and TUI TOTP/Authenticator storage

Project description

DOTP

Dank One Time Password - A CLI and TUI application for secure TOTP/Authenticator storage.

Tests Lint

TUI

Cli List

Features

  • Encrypted vault storage with password protection
  • CLI commands for managing TOTP entries
  • Interactive TUI for quick access
  • Import/Export support for Aegis and otpauth URI formats
  • Real-time token generation with auto-refresh
  • Search and filter capabilities with fuzzy matching
  • Clipboard integration
  • Clean, modern terminal UI with progress indicators

Installation

Using uvx (Recommended)

Run DOTP without installation:

uvx dotp --help

Global install

uv tool install dotp

Pip install

pip install dotp

Using uv (for development)

git clone https://github.com/rochacbruno/dotp.git
cd dotp
uv sync
uv run dotp --help

Quick Start

Initialize a vault

uvx dotp init

This creates an encrypted vault at ~/.config/dotp/.vault.dotp (or $XDG_CONFIG_HOME/dotp/.vault.dotp).

Add an entry

uvx dotp add --label GitHub --secret YOURBASE32SECRET

Or interactively:

uvx dotp add --label GitHub
# You'll be prompted for the secret

List all entries

uvx dotp list

Get a specific token

uvx dotp get GitHub

For scripting (clean output):

DOTP_PASSWD=123456 uvx dotp get GitHub | wl-copy

Import from file

DOTP supports importing from various formats. See the sample files in the repository:

# From otpauth URI format
uvx dotp import otpauth_sample.txt

# From Aegis JSON format
uvx dotp import aegis.json --aegis

Export to file

# To otpauth URI format
uvx dotp export backup.txt

# To Aegis JSON format
uvx dotp export backup.json --aegis

CLI

TUI Mode

Launch the interactive TUI by running dotp without arguments:

uvx dotp
# or with password from environment
DOTP_PASSWD=123456 uvx dotp
# or with custom vault path
uvx dotp --path /tmp/my-vault.dotp
# or with environment variable
DOTP_VAULT=/tmp/my-vault.dotp uvx dotp

TUI Features

  • Type to search: Start typing to filter entries in real-time
  • Enter in search: Focus results to navigate with arrow keys
  • Enter on item: Copy selected token to clipboard
  • Ctrl+Enter: Copy token and close application
  • Ctrl+A: Add a new entry
  • Ctrl+Q: Quit
  • Escape: Clear search
  • Backspace: Return to search when navigating results

Configuration

Create a config file at ~/.config/dotp/config.toml:

# Path to your vault file (optional)
vault_path = "/path/to/.vault.dotp"

# Close TUI immediately after copying (default: false)
close_on_copy = true

# Clipboard command to use (default: wl-copy)
clipboard_command = "wl-copy"

Environment Variables

  • DOTP_PASSWD: Set vault password (useful for scripting)
  • DOTP_VAULT: Set vault file path (alternative to --path or config file)

Vault Location Priority

DOTP looks for the vault in this order:

  1. --path argument
  2. DOTP_VAULT environment variable
  3. vault_path in config file
  4. .vault.dotp in current directory
  5. ~/.config/dotp/.vault.dotp

Security

  • Vault is encrypted using Fernet (symmetric encryption)
  • Password is derived using PBKDF2HMAC with SHA256
  • 480,000 iterations (OWASP recommended minimum)
  • 16-byte random salt per vault

Development

Running tests

uv sync --extra dev
uv run pytest

Running with coverage

uv run pytest --cov=src/dotp --cov-report=html

Linting

uvx ruff check src/
uvx ruff format src/

Stack

License

AGPL License - See LICENSE file for details

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dotp-0.1.2.tar.gz (12.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dotp-0.1.2-py3-none-any.whl (15.6 kB view details)

Uploaded Python 3

File details

Details for the file dotp-0.1.2.tar.gz.

File metadata

  • Download URL: dotp-0.1.2.tar.gz
  • Upload date:
  • Size: 12.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for dotp-0.1.2.tar.gz
Algorithm Hash digest
SHA256 5a7b96aa149494a48a04dd04078e9c31325d3273e85373753d2ffabcdb58cd36
MD5 e6889416d5253415978dbbab6f1f4956
BLAKE2b-256 e6e43559bd3fc05e0e1142122ede8ce85fd824c97acf8fdb7514769a3432429e

See more details on using hashes here.

File details

Details for the file dotp-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: dotp-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 15.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.9.2

File hashes

Hashes for dotp-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9a92023af632c95c8db221d59033e2f9f4beb400a692ffa2a5429780714fbfd9
MD5 ecedbfaada59e71d6dacbc0a943c33a0
BLAKE2b-256 76c6e8c29560307ac16bb4b368f70d238d8fcdf7432d2ae6cc9aa98afaf133a0

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page