πΒ Post-Quantum File Compression + Encryption (ML-KEM-1024 + AES-GCM + LZMA)
PQFileCompressAndLock is a post-quantum secure tool that performs:
-
π¦ Compression (LZMA SDK)
-
π Encryption (ML-KEM-1024 + AES-256-GCM)
-
π Decompression + Decryption
-
βοΈ Integrity Verification (SHA-256)
Designed to protect files against classical and quantum attacks.
1οΈβ£ High-Level Workflow
PQFileCompressAndLock works in a single step for the user, but internally it performs:
-
Compress file β
.lzma -
Generate Kyber-1024 keypair
-
Generate shared secret
-
Encrypt using AES-256-GCM
-
Package everything into a final encrypted file
Decryption performs the reverse process.
2οΈβ£ Main Features
π¦ LZMA Super-Compression
Reduces file size before encryption.
π Post-Quantum ML-KEM-1024
Key encapsulation resistant to quantum attacks.
π AES-256-GCM
Authenticated encryption with integrity built-in.
π Integrity Test Mode (--verify)
SHA-256 comparison of original vs restored file.
3οΈβ£ Folder Structure
The program automatically creates:
These are per-encryption ephemeral keys.
β οΈ They must remain next to the executable for decryption to work.
4οΈβ£ β Usage Summary (Very Simple)
π Encrypt
π Decrypt
βοΈ Verify Integrity
5οΈβ£ Sender Instructions (Encrypting a File)
π― Goal: deliver a post-quantum encrypted file to the recipient.
Step 1 β Run encryption
What happens internally
-
LZMA compression
-
Key generation
-
Shared secret encapsulation
-
AES-256-GCM encryption
-
Output file saved as
secure_output.enc
Step 2 β Send file
You send only:
Nothing else.
π« Never send:
-
keys/kyber.prv -
keys/kyber.pub -
keys/cipher.key
These must stay local.
6οΈβ£ Recipient Instructions (Decrypting a File)
π― Goal: restore the original file.
Step 1 β Place encrypted file next to the program
Example:
Step 2 β Run decryption
The system automatically:
-
Loads Kyber keys
-
Decapsulates shared secret
-
Decrypts using AES-GCM
-
Decompresses LZMA
-
Outputs
restored.pdf
Step 3 β Optional integrity check
If identical:
7οΈβ£ Security Model β Very Clear for Clients
βοΈ Post-quantum safe (ML-KEM-1024)
Protection even against future quantum computers.
βοΈ AES-256-GCM authenticated encryption
Data confidentiality + integrity.
βοΈ Keys are ephemeral per operation
Every encrypted file uses new keys and new symmetric secrets.
βοΈ No password-based encryption
Your clients never need to choose passwords or manage keyfiles manually.
8οΈβ£ What the Sender Must Know
β Run encryption
β Send encrypted file
β Keep local keys untouched
β They never need to decrypt anything
9οΈβ£ What the Recipient Must Know
β Keep the keys/ folder safe
β Run decryption
β Use --verify if needed
β Keys are automatically managed
π Quick Cheat Sheet (for printing)
π Final Notes for the Customer
PQFileCompressAndLock provides military-grade, quantum-resistant, and fully automatic file security.