Capacity Management & Hints Protocol
This guide explains the mathematical formulas governing embedding capacity, the adaptive Brotli compression protocol, and the zero-overhead hint storage model.
1. Embedding Capacity Formula
In the bit-mapping architecture, each bit of the compressed and encrypted secret payload matches a randomly selected bit in the cover text carrier. The Capacity Ratio is calculated as:
The system supports a maximum theoretical capacity ratio of 100% (1:1 byte-for-byte) without causing visual distortion. If the secret payload exceeds 100% of the available cover capacity, the UI prevents execution and displays an alert requesting a longer cover text.
2. Space Savings via Adaptive Brotli Compression
The Brotli compression engine reduces the secret text size before encryption, dynamically calculated as:
For repetitive natural text (such as English or Arabic paragraphs), Brotli achieves up to 55.5% space savings, effectively doubling the secret data capacity that can fit into a given cover text.
3. The 0xFE Flag Protocol
To eliminate dictionary bloat on extremely short strings (where compressed output is larger than plain text), the system employs an adaptive flag byte:
- Compressed Mode: If
CompressedBytes < RawBytes, a single prefix byte0xFEis prepended. - Bypass Mode: If
CompressedBytes ≥ RawBytes, the raw payload is transmitted directly without the0xFEflag.
4. Zero-Overhead Recovery Hints Protocol
The system allows senders to embed optional password hints or context tags without transmitting extra files. The payload codec formats the hint alongside the secret payload using a deterministic internal delimiter before compression and encryption.