Command-line tool to split files into multiple parts and reconstruct them later. Supports ZIP compression with AES-256 encryption.
- Split any file into N equal parts
- Optional ZIP compression with AES-256 encryption
- Full Unicode password support (including special characters like
ñ,Ñ,é, etc.) - Cross-platform: files split on Linux can be joined on macOS and vice versa
- Automatic MD5 integrity verification
- Automatically detects all parts in a sequence (provide any part, not just the first)
- Automatically detects if ZIP files require a password
- Fully interactive mode
- Option to delete fragments after reconstruction
- Python 3.8+
pyzipper— only needed for password protection. Installed automatically on first run if missing.
pip install pyzipperNo other external tools needed. p7zip / 7-Zip are no longer required.
git clone https://github.com/function0xmarki/carpenter.git
cd carpenter
chmod +x carpenter.pypython3 carpenter.py --split file.jpgThe program will ask interactively:
- How many parts? (minimum 2)
- Password protection? (y/n)
- Yes → asks for password and confirmation, generates
.zipfiles with AES-256 - No → generates plain
.partfiles
- Yes → asks for password and confirmation, generates
A subdirectory named after the file is created with all parts inside:
photo/
photo_0.zip ← metadata (MD5 + original filename), encrypted
photo_1.zip ← data part 1, encrypted
photo_2.zip ← data part 2, encrypted
Or without password:
photo/
photo_0.part ← metadata (MD5 + original filename)
photo_1.part ← data part 1
photo_2.part ← data part 2
python3 carpenter.py --join photo_2.zipYou can provide any part from the sequence — the program finds all parts automatically.
The program will:
- Locate all parts in the directory
- Ask for the password if the files are encrypted
- Reconstruct the original file
- Verify MD5 integrity
- Offer to delete the fragment files
python3 carpenter.py --helpWhen splitting photo.jpg into 3 parts:
| File | Content |
|---|---|
photo_0.part / photo_0.zip |
MD5 checksum + original filename |
photo_1.part / photo_1.zip |
Data (part 1 of 3) |
photo_2.part / photo_2.zip |
Data (part 2 of 3) |
photo_3.part / photo_3.zip |
Data (part 3 of 3) |
Part _0 contains metadata only. Parts _1 onward contain the actual data.
| Argument | Description |
|---|---|
--split <file> |
Split a file (interactive) |
--join <part> |
Reconstruct from any part in the sequence |
-h, --help |
Show help |
- Passwords are entered interactively and never displayed on screen
- Password confirmation required when splitting
- AES-256 encryption via pyzipper (WinZip AES format)
- Passwords are always encoded as UTF-8 before key derivation, ensuring identical results across Linux, macOS, and Windows
- MD5 checksum verifies file integrity after reconstruction
Note: Files created with password protection are only compatible with Carpenter or tools that support WinZip AES-256 encryption (such as 7-Zip or WinZip). Files created without a password are standard raw binary parts with no container format.
MIT License