๐ผ๏ธ pinlock-img v9
Authenticated PNG Image Vault
Secure โข Deterministic โข Authenticated Image Protection
๐ Overview
pinlock-img is a password-based image protection tool for PNG files.
It ensures:
- No silent corruption
- Safe failure on wrong password
- Tamper detection via authentication
๐ Core Design
๐ Key Derivation
- PBKDF2-HMAC-SHA256
- 200,000 iterations
- Salt:
pinlock-img-v9
๐ง Dual-Key Architecture
- XOR Seed (16 bytes) โ deterministic noise stream
- Authentication Key (16 bytes) โ HMAC-SHA256
๐ก๏ธ Authenticated Encryption
Encrypt-then-MAC design:
- Encrypt data
- Generate HMAC
- Store tag in PNG metadata (
pinlock_auth)
Decryption only proceeds after successful verification.
โ๏ธ How It Works
Encryption
- XOR transform applied
- HMAC generated
- Tag embedded in PNG
.lock suffix added
Decryption
- Extract HMAC
- Verify integrity
- If valid โ decrypt
- If invalid โ abort safely
๐ Features
- ๐ Password-based protection
- ๐ก๏ธ HMAC-SHA256 authentication
- ๐ Batch processing
- ๐งช Dry-run mode
- ๐พ Atomic file writes
๐ฆ Installation
Requires Python 3.8+
๐ Usage
python pinlock-img.py /path/to/file_or_directory
Dry Run
python pinlock-img.py /path/to/files
Then:
Dry Run? (y/n): y
โ ๏ธ Security Notes
- Strong authentication (HMAC-SHA256)
- PBKDF2 protects against brute-force
However:
- Uses deterministic XOR transformation
- Not equivalent to AES-GCM or modern AEAD
๐ License
MIT License ยฉ 2026 Fox Hackerz
๐ฆ About Fox Hackerz
We build tools focused on:
- Cybersecurity
- Automation
- Developer tools
๐ GitHub: https://github.com/foxhackerzdevs
๐ฆ Join the pack. Build. Break. Secure.