๐ Python Password Manager
A modular, secure, and easy-to-use password manager featuring a professional CLI interface, an interactive menu (TUI) with arrow-key navigation, full test coverage, and CI/CD.
๐ Key Features
- Modular Architecture: Full separation between the cryptographic logic (
core) and the CLI/storage interface. - Interactive Menu (TUI): Running
passmgrwith no arguments opens an arrow-key navigation menu built withquestionaryandrich, offering List / Get / Add / Delete / Generate options directly from the menu. - Strong Security: Key derivation via PBKDF2-HMAC-SHA256 (390,000 iterations by default) and Fernet symmetric encryption (AES-128-CBC + HMAC-SHA256).
- Local Encrypted Storage: The vault is stored in a single encrypted file (
vault.json). - Dedicated CLI Shortcut: Run the
passmgrcommand directly from the terminal, with or without subcommands. - Clipboard Integration: Quick password copying with a single keypress or a CLI flag (using
pyperclip). - Testing & CI/CD: Unit test coverage with
pytestand automated PyPI deployment via GitHub Actions.
Project Structure ๐
PASSWORD_MANAGER/
โโโ .github/
โ โโโ workflows/
โ โโโ publish.yml
โ โโโ test.yml
โโโ src/
โ โโโ password_manager/
โ โโโ cli/
โ โ โโโ __init__.py
โ โ โโโ main.py
โ โโโ core/
โ โ โโโ __init__.py
โ โ โโโ crypto.py
โ โ โโโ vault.py
โ โโโ __init__.py
โ โโโ interactive.py
โโโ tests/
โ โโโ test_crypto.py
โ โโโ test_vault.py
โโโ .gitignore
โโโ LICENSE
โโโ pyproject.toml
โโโ README.md
โโโ requirements.txt
๐ฆ Installation & Running
Option 1: Install from PyPI (Recommended)
pip install razeini-password-manager
Option 2: Install for Development
1. Clone the repository:
git clone https://github.com/RazEini/Password_Manager.git
cd Password_Manager
2. Install the package in editable mode:
pip install -e .
3. Run unit tests:
pip install pytest
pytest
๐ฅ๏ธ Interactive Mode (TUI)
Running the passmgr command without a subcommand opens a full interactive menu (requires rich and questionary):
passmgr
# or with a specific vault file:
passmgr --vault myvault.json
The menu automatically detects whether the vault exists:
- If it doesn't exist โ it will offer to create a new vault with a master password.
- If it exists โ it will prompt for the master password to unlock it.
Once unlocked, an arrow-key navigation menu is displayed with the following options:
| Menu Option | Description |
|---|---|
| List All Services | Display all services saved in the vault |
| Get Entry | View entry details, including an option to copy the password to the clipboard |
| Add / Update Entry | Add a new entry or update an existing one, with an option to generate a random password |
| Delete Entry | Delete an entry from the vault after confirmation |
| Generate Random Password | Generate a random password only, without saving it to the vault |
| Lock & Exit | Lock the vault and exit the menu |
๐ป CLI โ Main Commands (`passmgr`)
| Command | Description | Example |
|---|---|---|
(no command) |
Open the interactive menu (TUI) | passmgr |
init |
Create a new encrypted Vault | passmgr init |
add |
Add or update a password for a service | passmgr add --service github --user myusername |
get |
Retrieve a password (with an option to copy to clipboard) | passmgr get --service github --copy |
list |
List all existing services in the vault | passmgr list |
delete |
Delete an entry from the vault | passmgr delete --service github |
change-master |
Change the master password and re-encrypt | passmgr change-master |
generate |
Generate a strong random password | passmgr generate --length 20 |
export-csv |
Export passwords to a CSV file | passmgr export-csv --path backup.csv |
import-csv |
Import passwords from a CSV file | passmgr import-csv --path backup.csv |
๐ก Note on Custom Vault Names:
By default,passmgrusesvault.jsonin the current working directory. If you want to use a custom file name (e.g.,myvault.json), append--vault <filename>to any command:passmgr --vault myvault.json init passmgr --vault myvault.json add --service github --user myusername
๐ก๏ธ Security & Key Derivation
The application never stores the master password on disk at any stage. The cryptographic key is derived in real time from the master password and the dynamic Salt stored in the Vault file. Even in interactive mode, password entry is handled via questionary.password, which masks the characters as they're typed, just like getpass does in the standard CLI mode.
๐ License
This project is distributed under the MIT license โ free to use, modify, and distribute. For more information, see the LICENSE file.
๐จโ๐ป Raz Eini (2026)
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file razeini_password_manager-0.1.2.tar.gz.
File metadata
- Download URL: razeini_password_manager-0.1.2.tar.gz
- Upload date:
- Size: 14.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3e93a62c96200cf95d16b5d20128296f146ec1da3a858d75b161205d3b36eaeb
|
|
| MD5 |
bf525e4d6825dd928854f60191827a4a
|
|
| BLAKE2b-256 |
9cb7bb23abe3557cd920faced1909ee8993e6190f0f45f015bb7e72cda88da9e
|
File details
Details for the file razeini_password_manager-0.1.2-py3-none-any.whl.
File metadata
- Download URL: razeini_password_manager-0.1.2-py3-none-any.whl
- Upload date:
- Size: 13.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3237268c51eadacadb926c54c3c96e7a1264963fcb6c97b68294e6cb0d4a94fb
|
|
| MD5 |
36083cd9c2c870b0dfdd6b62a9b1d72e
|
|
| BLAKE2b-256 |
c568107361c08e48f04321aafd3efb0d1c3b72c754018a047f031591df3fc592
|