vault-tar
AES-256-GCM file and directory encryption with chunked streaming, configurable compression, and optional output splitting.
Features
- AES-256-GCM authenticated encryption with PBKDF2-HMAC-SHA256 key derivation (1 200 000 iterations by default).
- Chunked streaming — encrypts/decrypts in 1 MiB chunks so memory usage stays constant regardless of input size.
- Compression — choose between
xz,gz,bz2,zst(Python ≥ 3.14), ornone. - Output splitting — split encrypted output into fixed-size parts (default 1 GiB) for easier storage and transfer.
- Single-file mode — encrypt/decrypt individual files without tar archiving.
- Directory comparison — recursively compare two directory trees after a round-trip to verify integrity.
- Progress bars — optional verbose mode (
-v) with real-time byte-level progress during compression, encryption, and decryption.
Requirements
- Python ≥ 3.12
cryptography≥ 43.0
Installation
From PyPI
pip install vault-tar
From source
git clone https://github.com/l1asis/vault-tar.git
cd vault-tar
pip install .
Usage
After installation the vtar command is available on your PATH.
Encrypt directories
vtar encrypt -i secret_docs/ photos/ -o encrypted -v
Encrypt with a specific algorithm
vtar encrypt -i data/ -o data --algorithm zst -v # zstandard (Python ≥ 3.14)
vtar encrypt -i data/ -o data --algorithm gz -v # gzip
vtar encrypt -i data/ -o data --algorithm none -v # tar only, no compression
Encrypt a single file (skip archiving)
vtar encrypt -i backup.sql -o backup.enc --file-only --no-split
Decrypt
vtar decrypt -i encrypted -o restored/ -v
vtar decrypt -i backup.enc -o backup.sql --file-only
Compare directories
Verify that decrypted output matches the original:
vtar compare original/ restored/ -v
Additional options
| Flag | Description |
|---|---|
-v, --verbose |
Show progress bars and status messages |
--password TEXT |
Supply password on command line (prompted if omitted) |
--algorithm {xz,gz,bz2,zst,none} |
Compression algorithm (default: xz) |
--compression-level N |
Algorithm-specific compression level |
--chunk-size SIZE |
Plaintext chunk size (default: 1MiB) |
--split-size SIZE |
Max part-file size (default: 1GiB) |
--no-split |
Write a single output file |
--file-only |
Encrypt/decrypt a single file directly |
--cleanup |
Remove original input after success |
-V, --version |
Show version and exit |
Sizes accept human-readable suffixes: KiB, MiB, ... TiB
for binary units (default), as well as KB, MB, ... TB
for decimal units.
File format
All encrypted output follows a custom binary format (v1):
Header (first part only):
[2 B] magic 0xEF01
[1 B] format version 0x01
[2 B] salt length [N B] salt
[2 B] base-nonce length [12 B] base nonce
Chunks (sequential across parts):
[4 B] ciphertext length [N B] ciphertext (plaintext + 16 B GCM tag)
Each chunk uses a unique nonce derived as base_nonce XOR chunk_index
(big-endian, 12 bytes) with AAD b"chunk_<index>".
Security
See SECURITY.md for the threat model, cryptographic details, known limitations, and responsible disclosure policy.
Acknowledgments
Built with assistance from GitHub Copilot (Claude Opus 4.6).
License
MIT — Copyright 2026 Volodymyr Horshenin
Metadata
Release files for vault-tar 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| vault_tar-0.1.2.tar.gz | 26.7 kB | With provenance | Details for vault_tar-0.1.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| vault_tar-0.1.2-py3-none-any.whl | Python 3 | none | any | Details for vault_tar-0.1.2-py3-none-any.whl |
Total release size: 42.4 kB
Release files / vault_tar-0.1.2.tar.gz
| Download URL | vault_tar-0.1.2.tar.gz |
|---|---|
| Size | 26.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
673e5f0cb6929e40325122215997066a90283a8f68d4ec7edaba0f592661a65b
|
|
BLAKE2b-256 checksum How to use checksums |
cbc7799abfb094b4aae3ad0a5a75b4a244b161840d89850f9ba732babb164047
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 14, 2026.
Transparency logRelease files / vault_tar-0.1.2-py3-none-any.whl
| Download URL | vault_tar-0.1.2-py3-none-any.whl |
|---|---|
| Size | 15.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
cb510bbe5164443308dbf3041d5af71f539facab60db7ea889569efc426c7262
|
|
BLAKE2b-256 checksum How to use checksums |
9e21a2b6ec51e961a825a642825a06f1275e6f7eb7084626fbb26a40ce3f9d8e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.7
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 14, 2026.
Transparency logSecurity for vault-tar 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
Full provenance
All 2 files in this release have been uploaded with provenance metadata.
Attestation for vault_tar-0.1.2.tar.gz
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Feb 14, 2026.
Transparency logA note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.