Skip to main content

A secure local password manager

Project description

๐Ÿ” Password Manager

A secure Password Manager built with Python that securely stores your passwords locally using strong encryption.

๐Ÿš€ Features

  • Secure Storage: All passwords encrypted with Fernet symmetric encryption
  • Password Management: Add, view, edit, and delete passwords
  • Security Analysis: Password strength evaluation and suggestions
  • Password Generator: Create strong, random passwords
  • Master Password: Protect access with a master password
  • Two-Factor Authentication: Additional security with TOTP (Time-based One-Time Password)
  • Categorization: Organize passwords by category
  • Security Audit: Find weak, reused, expired, or breached passwords
  • Backup & Restore: Export/import functionality
  • Password Expiration: Set expiry dates for passwords
  • Command-Line Interface: User-friendly CLI with color formatting
  • GUI Interface: Optional PyQt5 graphical interface
  • Activity Logging: Track all important actions

๐Ÿ› ๏ธ Installation

Option 1: Install from PyPI (Recommended)

The simplest way to install Secure Password Manager:

pip install secure-password-manager

After installation, you can run the application with:

# For the command-line interface
password-manager

# For the graphical interface
password-manager-gui

Option 2: Install from Source

  1. Clone the repository:

    git clone https://github.com/ArcheWizard/password-manager.git
    cd password-manager
    
  2. Create and activate a virtual environment:

    python3 -m venv venv
    source venv/bin/activate   # On Windows: venv\Scripts\activate
    
  3. Install the package in development mode:

    pip install -e .
    

๐Ÿ›ก๏ธ Requirements

  • Python 3.8+
  • Core dependencies (installed automatically):
    • cryptography: For secure encryption
    • PyQt5: For the GUI interface
    • zxcvbn: For password strength analysis
    • pillow: For image processing
    • Additional dependencies as listed in requirements.txt

๐Ÿ“‚ Project Structure

The project is organized into modules for maintainability and separation of concerns:

password-manager/
โ”œโ”€โ”€ apps/                  # Application code
โ”‚   โ”œโ”€โ”€ __init__.py        # Package initialization
โ”‚   โ”œโ”€โ”€ app.py             # CLI application entry point
โ”‚   โ””โ”€โ”€ gui.py             # GUI application entry point
โ”œโ”€โ”€ utils/                 # Core utilities
โ”‚   โ”œโ”€โ”€ auth.py            # Authentication
โ”‚   โ”œโ”€โ”€ backup.py          # Import/export 
โ”‚   โ”œโ”€โ”€ crypto.py          # Encryption/decryption
โ”‚   โ”œโ”€โ”€ database.py        # Database operations
โ”‚   โ”œโ”€โ”€ interactive.py     # CLI input utilities
โ”‚   โ”œโ”€โ”€ logger.py          # Logging facilities
โ”‚   โ”œโ”€โ”€ password_analysis.py # Password evaluation
โ”‚   โ”œโ”€โ”€ security_analyzer.py # Breach checking
โ”‚   โ”œโ”€โ”€ security_audit.py  # Security auditing
โ”‚   โ”œโ”€โ”€ two_factor.py      # 2FA implementation
โ”‚   โ””โ”€โ”€ ui.py              # UI formatting
โ”œโ”€โ”€ tests/                 # Unit & integration tests
โ””โ”€โ”€ README.md              # Project documentation

๐Ÿ“ธ Screenshots

Home Screen

Home Screen

Adding a Password

Add Password

Editing a Password

Edit Password

Security Audit

Security Audit

Backup Options

Backup

Exporting Passwords

Export

Importing Passwords

Import

๐Ÿ”’ How It Works

Security Model

This Password Manager uses a multi-layered security approach:

  1. Master Password: Access to the application is protected by a master password that is never stored directly. Instead, a salted hash is stored using PBKDF2 with 100,000 iterations.

  2. Encryption: All passwords are encrypted using Fernet symmetric encryption (AES-128 in CBC mode with PKCS7 padding).

  3. Key Management: The encryption key is stored locally and is used for encrypting/decrypting the stored passwords.

  4. Database: Passwords are stored in a local SQLite database, with the password values stored as encrypted binary data.

  5. Backup Protection: When exporting passwords, the entire backup file is encrypted using the same strong encryption.

Data Flow

  1. When adding a password:

    • Password is encrypted using the local key
    • Encrypted data is stored in the SQLite database
  2. When viewing passwords:

    • Encrypted data is retrieved from the database
    • Each password is decrypted for display
  3. When exporting passwords:

    • All passwords are decrypted
    • The entire password list is serialized to JSON
    • The JSON is encrypted and written to a file

๐Ÿ“š Future Improvements

  • โœ… Add a Master Password authentication
  • โœ… Password strength evaluation and generator
  • โœ… Unit tests for critical functions
  • โœ… Backup and restore functionality
  • โœ… Add a search function for passwords
  • โœ… Add password categories/tags
  • โœ… Add password expiration notifications
  • โœ… GUI version (PyQT)
  • โœ… Package available on PyPI
  • Two-factor authentication
  • Password history tracking
  • Cross-platform desktop application (using PyInstaller)
  • Docker support

๐Ÿ‘จโ€๐Ÿ’ป Author

๐Ÿ“„ License

This project is licensed under the MIT License - see the 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

secure_password_manager-1.7.0.tar.gz (38.7 kB view details)

Uploaded Source

Built Distribution

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

secure_password_manager-1.7.0-py3-none-any.whl (41.2 kB view details)

Uploaded Python 3

File details

Details for the file secure_password_manager-1.7.0.tar.gz.

File metadata

  • Download URL: secure_password_manager-1.7.0.tar.gz
  • Upload date:
  • Size: 38.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.3

File hashes

Hashes for secure_password_manager-1.7.0.tar.gz
Algorithm Hash digest
SHA256 57d74ea4f417ab148cb8cd71c7211dbde784d698b1327f8d3e63d4edbb01fb80
MD5 eed1cfb995fc15196171cff93cde68b2
BLAKE2b-256 52d81e0101387254f7aad5657f0d6bb2aaadff67f61c9ca2989884f973d6385d

See more details on using hashes here.

File details

Details for the file secure_password_manager-1.7.0-py3-none-any.whl.

File metadata

File hashes

Hashes for secure_password_manager-1.7.0-py3-none-any.whl
Algorithm Hash digest
SHA256 4feeed383f0219a6de350bd824263e8e0024b199cfebeea936e2801f29ffe4ed
MD5 582216a2f393f9f65668ce2f6bdf333c
BLAKE2b-256 eeddf2f3e4bda245d3e4b0fa1d7fe5449a4fa38ac0914e0375fec3c413cadd11

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