Lazarus is a specialized compression engine written in Rust, engineered for long-term data preservation and secure archival. It integrates deep entropy reduction (LZMA) with block-level integrity fingerprints (CRC-32), cryptographic confidentiality (ChaCha20-Poly1305), and mathematical self-healing (Wirehair Fountain Codes).
The primary objective of Lazarus is to ensure that archived data remains retrievable and private even when stored on unstable media or subjected to partial bit-rot and physical corruption.
Lazarus utilizes a multi-layered approach to data protection:
- Adaptive Block Chunking: Input data is partitioned into dynamic blocks (ranging from 4KB to 1MB) based on total file size. This strategy balances metadata overhead against the granularity of potential data recovery.
- DNA Fingerprinting: Every block undergoes CRC-32 verification before and after the compression/encryption stages. These fingerprints serve as the authoritative ground truth during the reconstruction process.
- Entropy Reduction: Data is compressed using LZMA (Level 9) to achieve maximum theoretical density.
- Secret Shield (Confidentiality): When enabled, compressed blocks are encrypted using the ChaCha20-Poly1305 AEAD algorithm. Encryption keys are derived from user passwords using the Argon2id key derivation function (KDF).
- Phoenix Protocol (Self-Healing): Lazarus applies Wirehair Fountain Codes to generate an adaptive parity shield (3% to 10% overhead). This allows for bit-perfect reconstruction of corrupted blocks without requiring original source data.
- Structural Redundancy: The archive utilizes a dual-header "Brain Backup" strategy. If the primary header fails integrity checks, the system automatically resurrects the archive structure from a redundant metadata block.
The following table summarizes the capabilities of Lazarus v0.1.7 compared to industry-standard archival tools.
| Feature | Lazarus | XZ / 7-Zip | Gzip / Zip |
|---|---|---|---|
| Primary Algorithm | LZMA (L9) | LZMA2 | DEFLATE |
| Integrity Check | Block-Level (DNA) | Stream-Level | File-Level |
| Confidentiality | ChaCha20-Poly1305 | AES-256 | Mixed |
| Self-Healing | Built-in (Phoenix) | None | None |
| Parallelism | Rayon (Multithreaded) | Semi-Supported | Limited |
| Data Resurrection | Mathematical | External Parity Only | None |
| Architecture | x86_64 / ARM64 | Universal | Universal |
Recent testing conducted on an x86_64 environment using Lazarus v0.1.7.
Tests were conducted by injecting 1KB of random data (corruption) into the archive data stream.
| File Type | Original Size | Lazarus Size | Reduction | Chaos Resilience |
|---|---|---|---|---|
| Server Logs | 50 MB | 196 KB | 99.63% | SUCCESS (Healed) |
| JSON Data | 50 MB | 2.2 MB | 95.48% | SUCCESS (Healed) |
| Binary Data | 10 MB | 10.6 MB | -5.93% | SUCCESS (Healed) |
Note: Binary data archives include a higher adaptive parity overhead (10%) to ensure recovery for high-entropy payloads.
Ensure the Rust toolchain is installed, then execute:
cargo build --release
sudo cp target/release/lazarus /usr/bin/Official packages are available on the GitHub Releases page:
sudo dpkg -i lazarus_0.1.7_amd64.debTo compress a file or an entire directory:
lazarus compress <path>To enable encryption (Secret Shield):
lazarus compress <path> --password "your-secure-phrase"To decompress and verify an archive:
lazarus decompress <file.lzr>For encrypted archives:
lazarus decompress <file.lzr> --password "your-secure-phrase"- Concurrency: Lazarus leverages the
rayonlibrary for parallel processing of compression and encryption blocks, significantly reducing wall-clock time on multi-core systems. - Key Derivation: Argon2id is utilized for password-to-key conversion, providing high resistance against GPU-based brute-force attacks.
- Error Correction: The
wirehair-wrappercrate provides the underlying fountain code logic for data resurrection.
Comprehensive technical documentation, implementation reports, and detailed performance analysis can be found in the docs/ directory.
This project is licensed under the MIT License. See LICENSE for details. Copyright (c) 2026 Azzar Budiyanto.