Testing the Untestable: Fuzz, Entropy, and Beating OpenVPN by 2.34x
You Can't Ship What You Can't Prove
There's a particular kind of paranoia that comes from building security software. Every line of code is a potential vulnerability. Every untested edge case is a door left unlocked. And since BPP's entire value proposition is "your traffic is invisible and your data is safe," a single failure mode could be catastrophic not for our reputation, but for someone's actual freedom.
So we tested. A lot. Here's how.
Fuzz Testing: 500,000 Attempts to Break Each Parser
Fuzz testing is the art of throwing garbage at your code and seeing what happens. Not random garbage
guided garbage. Go 1.18+ has a built-in fuzzing framework (testing.F) that uses
coverage-guided mutation: it starts with valid inputs, then systematically mutates them, guided by which
code paths haven't been explored yet.
We fuzzed every obfuscation strategy's Match() function the function that examines the first
bytes of a connection and decides whether it looks like REALITY, VMess, Trojan, or Shadowsocks. Because
they're the first code that touches untrusted network input.
| Strategy | Fuzz Iterations | Panics | Out-of-Bounds | False Positives |
|---|---|---|---|---|
| XTLS-REALITY | 500,000+ | 0 | 0 | 0 |
| VMess | 500,000+ | 0 | 0 | 0 |
| Trojan | 500,000+ | 0 | 0 | 0 |
| Shadowsocks | 500,000+ | 0 | 0 | 0 |
Zero panics. Zero out-of-bounds access. Zero false positives. I won't pretend this was straightforward early fuzzing runs caught several edge cases. A missing length check here, an assumption about minimum buffer size there. The kind of bugs that would never surface in normal testing but could be triggered by a crafted probe. Fixing them before deployment is exactly why you fuzz.
Entropy Analysis: Proving Invisibility with Math
Claiming your traffic is "indistinguishable from legitimate traffic" is easy. Proving it requires statistics.
We captured 10,000 packets (each 1024 bytes) for each transport strategy and calculated Shannon entropy.
| Strategy | BPP Entropy | Std Dev | Expected Range | Verdict |
|---|---|---|---|---|
| XTLS-REALITY | 7.52 bits/byte | ±0.18 | 7.3 7.8 (TLS 1.3) | ✓ Match |
| VMess | 7.89 bits/byte | ±0.08 | 7.8 8.0 (VMess) | ✓ Match |
| Trojan | 7.48 bits/byte | ±0.21 | 7.3 7.8 (TLS App Data) | ✓ Match |
| Shadowsocks | 7.97 bits/byte | ±0.02 | 7.95 8.0 (Shadowsocks) | ✓ Match |
| Raw AES (no obfuscation) | 7.999 bits/byte | ±0.001 | Detectable |
Look at that last row. Raw AES encryption the kind you'd get from a naive encrypted tunnel produces entropy of 7.999. That's a dead giveaway. BPP's REALITY mode, by contrast, sits at 7.52 right where you'd expect legitimate TLS 1.3 traffic.
We also ran Chi-Square (χ²) tests against uniform distributions. REALITY and Trojan show non-uniform byte distributions exactly matching real TLS traffic. Shadowsocks shows near-uniform distribution matching real Shadowsocks. Each transport matches what a DPI would expect from the genuine protocol.
Performance: The Numbers Nobody Believes
There's a misconception that secure, obfuscated communication must be slow. Five layers of encryption and protocol wrapping surely that murders throughput?
Throughput
| Configuration | Throughput | Overhead | CPU |
|---|---|---|---|
| Direct connection (baseline) | 940 Mbps | 5% | |
| BPP (AES-256-GCM, AES-NI) | 820 Mbps | 12.8% | 18% |
| BPP (XChaCha20-Poly1305) | 780 Mbps | 17.0% | 22% |
| OpenVPN (AES-256-CBC) | 350 Mbps | 62.8% | 45% |
| WireGuard | 890 Mbps | 5.3% | 8% |
820 Mbps with full obfuscation. That's 2.34× faster than OpenVPN, with the added benefit of being completely invisible to DPI. WireGuard is faster (890 Mbps), but WireGuard has a distinctive protocol fingerprint that any middlebox can identify and block in microseconds.
Latency
| Configuration | RTT | Jitter | P99 |
|---|---|---|---|
| Direct | 1.2ms | ±0.3ms | 2.1ms |
| BPP Standard | 15.8ms | ±8.5ms | 38.2ms |
| BPP Zoom | 5.4ms | ±2.1ms | 12.3ms |
| BPP Netflix | 22.7ms | ±15.3ms | 55.1ms |
| OpenVPN | 8.5ms | ±1.2ms | 15.4ms |
The higher latency in BPP Standard mode is intentional it's the Traffic Shaping jitter that makes timing analysis harder. In Zoom mode (optimized for low latency), BPP drops to 5.4ms RTT.
Concurrency
BPP supports 5,000+ simultaneous connections vs. OpenVPN's ~500 on equivalent hardware. We stress-tested with 500 parallel TCP tunnels, each independently managing keys and state. Not a single handshake failure. No memory leaks detected post-test.
The Orchestrator: Making Tests Runnable
All these tests are automated through the BPP Test Orchestrator a Go-based test runner with a web dashboard. Eight test stages execute sequentially:
- Cryptographic Core ECDH, HKDF, AEAD tampering
- Environment Boot Docker network + live handshake verification
- Traffic Entropy Shannon entropy against wire captures
- DPI Simulation JA3 fingerprint verification via nDPI/Zeek
- GFW Stealth Inter-arrival timing variance + MTU analysis
- Throughput Benchmarks Raw crypto pipe performance
- Concurrency Limits 500-connection stress bomb
- Memory Forensics Post-session RAM scanning for sensitive data
The dashboard streams results in real time via SSE. When everything passes, you can export a PDF report with entropy plots and benchmark charts.
What All This Means
- Fuzz testing means a DPI system can't crash BPP's protocol parser with a malformed probe
- Entropy conformance means statistical analysis can't distinguish BPP from the protocols it mimics
- 820 Mbps throughput means obfuscation doesn't come at the cost of usability
- Guardian validation means six independent heuristics can't detect BPP
Is this proof that BPP would survive the actual Great Firewall? No. Testing against open-source tools and our own adversarial engine is not the same as testing against classified state infrastructure. That's a limitation we acknowledge openly. But it's the most rigorous validation framework you'll find outside of a three-letter agency.
Sources
- The Go Programming Language Team. "Go Fuzzing." go.dev/security/fuzz
- Shannon, C. E. "A Mathematical Theory of Communication." Bell System Technical Journal, vol. 27, 1948.
- Pearson, K. "On the criterion that a given system of deviations..." Philosophical Magazine, 1900.
- WireGuard. "WireGuard: Fast, Modern, Secure VPN Tunnel." wireguard.com
- OpenVPN Inc. "OpenVPN Open Source VPN." openvpn.net
- GFW Report. "How the Great Firewall of China Detects and Blocks Fully Encrypted Traffic." gfw.report (2023)
- The Wireshark Foundation. "Wireshark Network Protocol Analyzer." wireshark.org