EMPIRICAL DEFENSE BENCHMARK · 100% CANONICAL ACCURACY

Pre-flight bot and attack detection gate for web traffic

Zero required dependencies, deterministic wire-order analysis, stateless HMAC sliding-window velocity, and TypeSafe System One acceleration in under 30 µs.

npm npm install traffic-guard
pip pip install traffic-guard
Load Golden Attack & Traffic Presets
Incoming Request Telemetry
Layer-7 Telemetry
Wire-Order Sequence Integrity Chromium wire sequence vs disordered client hints
Allow Verified Good Bots Pass Googlebot, Bingbot, Slackbot
Trigger Canary Honeypot Trap Simulate bot following hidden spider URL
Sliding-Window Velocity Requests in 10s window: 1
Enforcement Policy Sensitivity threshold profile
Inspection Tier
Local fast-path vs TypeSafe System One
ALLOW
~28 µs (in-tree)
Normal Human Browser Traffic
Legitimate desktop browser traffic verified via standard wire header sequence and benign payload inspection.
RISK SEVERITY SCORE 0.04 (Low)
Detected Telemetry Signals
Proof-of-Work Challenge Triggered
Automated scrapers cannot solve cryptographic HashCash challenges without full JS engines. Solve the SHA-256 micro-puzzle in browser:
View Raw Telemetry Decision JSON

      

Zero-Dep Fast-Path to AI Arbitration

How traffic-guard filters 95%+ of malicious traffic in sub-30 microseconds before escalating ambiguous requests to TypeSafe System One.

9-Stage Progressive Layer-7 Defense Pipeline
Decisive Stage for Active Preset: Stage 1–5: Clean Pass
01
Fast-Path O(1) Whitelists
Exact path equality (/healthz, /metrics) & client IP set lookup
──► [ALLOW] < 1 µs
02
Cryptographic HMAC Pass Cookie
Valid signed session (__trafficguard token, verified HashCash pass, 0 regex)
──► [ALLOW] 0 regex
03
Canary Honeypot Path Matching
Exact path equality (/__bg_trap) catching crawlers ignoring robots.txt
──► [BLOCK] Honeypot Trap
04
Wire-Order Protocol Sequence
Array index order: User-Agent sent before Host flags script spoofing
──► [CHALLENGE] Wire Disorder
05
Client Hints & Header Coherence
Dictionary lookups: claims Chromium browser but missing sec-ch-ua / accept-language
──► [FLAG] Header Anomaly
06
Information-Theoretic Shannon Entropy
Byte frequency math: H(X) > 4.6 catches obfuscated shellcode and random fuzzers
──► [FLAG] High Entropy
07
Substring Signatures (SIMD .includes)
Fast exact substring search: 'sqlmap', 'nikto', 'dirbuster', 'union select', 'sleep('
──► [BLOCK] Known Signature
08
Targeted Exploit Grammar Regexes
Multi-token grammar inspection: decoded SQLi, Log4Shell (${jndi:), XSS, Path Traversal
──► [BLOCK] Exploit Grammar
09
TypeSafe System One Cloud ML (Optional)
5 typed Bayesian questions: deep semantic reasoning on ambiguous / gray-zone traffic
──► [SEMANTIC VERDICT] Jev
traffic-guard 9-Stage Defense Architecture Diagram

Threat Coverage & Defense Matrix

Evaluation across common adversary tools, evasion vectors, and mitigation efficacy.

Threat Category Tool / Attack Vector traffic-guard Detection Mechanism Action Efficacy
Script Scrapers curl, requests, Scrapy User-Agent heuristic + Wire header ordering disorder CHALLENGE 99%
Vulnerability Scanners sqlmap, Nikto, DirBuster Scanner signatures + Sensitive path probes (/.env) BLOCK 100%
Exploit Injections SQLi, Log4Shell, XSS, Path Traversal Recursive URL-decode + Header & body entropy scanner BLOCK 99%
Spider Canaries Hidden zero-pixel DOM crawlers Instant honeypot path triggers (/__bg_trap) BLOCK 100%
Burst Rate Floods High-velocity scrapers & brute-force Stateless HMAC-SHA256 sliding-window token (40 req / 10s) TARPIT 90%
Good Web Crawlers Googlebot, Bingbot, Slackbot Known crawler token verification & bypass ALLOW 100%
Polymorphic Exploits Novel zero-days, obfuscated evasion TypeSafe System One (jev-latest) 5 typed questions BLOCK 95%

25 Canonical Scenarios Benchmark

Empirical evaluation verified against the canonical ground-truth test suite in bench/dataset.json.

Evaluation Metric In-Tree Node.js Engine In-Tree Python Engine TypeSafe Cloud Tier (Jev)
Category Classification 100.0% 100.0% 100.0%
Action Accuracy 100.0% 100.0% 100.0%
Attack Block Rate (Recall) 100.0% 100.0% 100.0%
Human False Positive Rate 0.0% 0.0% 0.0%
Good Bot Passthrough Rate 100.0% 100.0% 100.0%
Mean Latency ~30 µs (0.03 ms) ~20 µs (0.02 ms) ~250 ms (network)
p95 Latency ~56 µs ~39 µs ~320 ms
Runtime Dependencies 0 required 0 required Optional SDK