# SRX v1.0.0 Release Notes

**Release Date:** February 2026

We're excited to announce the first stable release of **SRX** - a modern, secure, compressed archive format designed for performance, security, and extensibility.

---

## 🎉 Highlights

SRX v1.0.0 is the first production-ready release of our secure archive format. Built from the ground up with modern cryptographic primitives and optimized for today's hardware.

---

## ✨ Features

### Security

- **Authenticated Encryption** - XChaCha20-Poly1305 AEAD cipher with per-chunk authentication
- **Password Protection** - Argon2id key derivation (64 MiB memory, 3 iterations, 4 threads)
- **Integrity Verification** - BLAKE3 hash for whole-file integrity
- **No Custom Crypto** - Only proven, battle-tested cryptographic primitives

### Performance

- **Fast Compression** - Zstd (default) or LZ4 compression algorithms
- **Chunk-Level Parallelism** - Process multiple chunks simultaneously
- **Random Access** - Extract portions without decompressing the entire archive
- **Streaming Support** - Process files larger than available memory

### Format

- **Extensible TLV Metadata** - Future-proof design for backward compatibility
- **Per-Chunk Authentication** - Early detection of corruption or tampering
- **Magic Bytes** - `SRX1` identifier for easy format detection

---

## 📦 Command Line Interface

### Pack Files

```bash
srx pack <INPUT> <OUTPUT> -p <PASSWORD> [OPTIONS]
```

Options:
- `-a, --algo` - Compression algorithm: `zstd` (default), `lz4`, `none`
- `-l, --level` - Compression level (0-22), default: 3

### Unpack Files

```bash
srx unpack <INPUT> -p <PASSWORD>
```

### View Archive Info

```bash
srx info <INPUT> -p <PASSWORD>
```

---

## 🔧 Compression Algorithms

| Algorithm | Speed | Ratio | Best For |
|-----------|-------|-------|----------|
| `zstd` | Fast | Good | General use (default) |
| `lz4` | Very Fast | Moderate | Speed-critical applications |
| `none` | Instant | 1:1 | Pre-compressed data (images, videos) |

---

## 📋 System Requirements

- **Rust**: 1.70 or later
- **OS**: Linux, macOS, Windows
- **Architecture**: x86_64, ARM64

---

## 🚀 Installation

### From Source

```bash
git clone https://github.com/Jamshed-develop/srx.git
cd srx
cargo build --release
```

The binary will be at `./target/release/srx`.

### Using Cargo

```bash
cargo install srx
```

---

## 📚 Library Usage

Add to your `Cargo.toml`:

```toml
[dependencies]
srx = { git = "https://github.com/Jamshed-develop/srx.git" }
```

### Example: Pack a File

```rust
use srx::{Packer, compression::CompressionAlgo};

let packer = Packer::new("secure_password".to_string())
    .compression_algo(CompressionAlgo::Zstd)
    .compression_level(3);

packer.pack("input.txt", "output.srx")?;
```

### Example: Unpack a File

```rust
use srx::Unpacker;

let unpacker = Unpacker::new("secure_password".to_string());
unpacker.unpack("archive.srx")?;
```

---

## 🔒 Security Model

### Protected Against

| Threat | Protection |
|--------|------------|
| Passive eavesdropping | Encrypted data unreadable without password |
| Data tampering | Poly1305 authentication detects modification |
| Chunk manipulation | Per-chunk tags prevent reordering/replacement |
| Password cracking | Argon2id resists brute-force attacks |
| Chosen-ciphertext attacks | AEAD construction is provably secure |

### Recommendations

1. Use strong passphrases (4+ random words)
2. Use unique passwords for each archive
3. Store passwords in a secure vault
4. Keep encrypted archives in multiple locations

---

## 📁 File Format

```
┌─────────────────────────┐
│      Fixed Header       │  32 bytes
├─────────────────────────┤
│   TLV Metadata Section  │  Variable
├─────────────────────────┤
│    Chunk Index Table    │  Variable
├─────────────────────────┤
│   Encrypted Data Chunks │  Variable
├─────────────────────────┤
│    Integrity Footer     │  32 bytes
└─────────────────────────┘
```

See [SPEC.md](SPEC.md) for complete specification.

---

## 🙏 Acknowledgments

SRX is built on these excellent crates:

- **chacha20poly1305** - XChaCha20-Poly1305 encryption
- **argon2** - Password hashing
- **blake3** - Fast cryptographic hash
- **zstd** - Zstandard compression
- **lz4_flex** - LZ4 compression
- **clap** - CLI argument parsing

---

## 📝 License

Licensed under **GNU General Public License v3.0**

- ✅ Free to use, modify, and distribute
- ✅ Copyleft - derivative works must also be GPL v3
- ✅ Must provide source code when distributing

---

## 🔮 What's Next

### Planned for v1.1

- Multi-file archive support
- Password change without re-encryption
- Progress callbacks for library users
- Pre-built binaries for Windows/macOS/Linux
- Archive verification mode (`srx verify`)

### Planned for v1.2

- Random access read/write
- Streaming mode for arbitrarily large files
- Parallel encryption/decryption
- File comments and timestamps

---

## 🐛 Known Issues

None at this time. Please report any issues on our [GitHub Issues](https://github.com/Jamshed-develop/srx/issues) page.

---

## 📥 Download

- **Source Code**: [GitHub Repository](https://github.com/Jamshed-develop/srx)
- **Crates.io**: `cargo install srx`

---

**Thank you for using SRX!** 🎉

Made with ❤️ in Rust