Skip to main content

Secure file & directory encryption CLI

Project description

CryptLock 🔐

Secure file & directory encryption CLI using AES-256-CFB with PBKDF2 key derivation.

Installation

pip install cryptlock

Usage

Encrypt a file

cryptlock encrypt myfile.txt

Encrypt and wipe original

cryptlock encrypt myfile.txt --wipe

Encrypt a directory

cryptlock encrypt myfolder --wipe

Decrypt a file

cryptlock decrypt myfile.txt.enc

Keep encrypted file after decryption

cryptlock decrypt myfile.txt.enc --keep

Features

  • AES-256-CFB encryption - Industry-standard symmetric encryption
  • PBKDF2-SHA256 - 600,000 iterations for key derivation (OWASP 2023 recommendation)
  • HMAC-SHA256 - Integrity verification (Encrypt-then-MAC)
  • Directory support - Automatically zips and encrypts folders
  • Progress bar - Visual feedback for large files
  • Cross-platform - Works on Linux, macOS, and Windows
  • Secure wipe - Best-effort secure deletion of original files

Security Notes

⚠️ Important Security Considerations:

  1. Secure deletion limitations: The --wipe flag attempts to overwrite files, but this is NOT cryptographically secure on:

    • SSDs (due to wear leveling)
    • Copy-on-write filesystems (btrfs, ZFS)
    • Journaling filesystems

    For true secure deletion, use full-disk encryption.

  2. Password strength: Use strong, unique passwords. The tool uses 600,000 PBKDF2 iterations, but weak passwords can still be brute-forced.

  3. Backup your data: Always maintain backups before encrypting important files.

Requirements

  • Python 3.8+
  • cryptography
  • tqdm

License

MIT License

Disclaimer

This tool is provided for educational and legitimate security purposes only. The authors are not responsible for any misuse or data loss.

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

cryptlock-1.1.1.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

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

cryptlock-1.1.1-py3-none-any.whl (6.1 kB view details)

Uploaded Python 3

File details

Details for the file cryptlock-1.1.1.tar.gz.

File metadata

  • Download URL: cryptlock-1.1.1.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for cryptlock-1.1.1.tar.gz
Algorithm Hash digest
SHA256 28792658095ebc8594ab6eb4addaef17f888f5f07a047977f6018045f9000d7a
MD5 3faac002ed539e9ab88a3d86b118ad01
BLAKE2b-256 18669f45c86bd1694fa008925a78491cf76e83be6fa2afc55786777e4256a2a6

See more details on using hashes here.

File details

Details for the file cryptlock-1.1.1-py3-none-any.whl.

File metadata

  • Download URL: cryptlock-1.1.1-py3-none-any.whl
  • Upload date:
  • Size: 6.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for cryptlock-1.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 9ecce56b4cdaa33a32d285267678d531ec66325f9d12a7d697925dcca1082823
MD5 4510c0cc188a3473b851cbe1fc0d6ef4
BLAKE2b-256 a7d8f726de997030647ef100d5c2b3ef112ab85559afc54c630bd60ad221e003

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