Repository navigation
Releases
Releases · ejames-dev/NetDIFT
NetDIFT v0.1.0
NetDIFT v0.1.0: Initial Public Release
NetDIFT is a deterministic, zero-LLM gateway written in Rust. It performs network-layer Dynamic Information Flow Tracking (DIFT) and enforces monotonic capability attenuation for internal AI agents. Once an agent session reads untrusted or confidential data, its outbound capabilities can only shrink. Prompts cannot raise them again, and the only exception is a single-use, narrowly scoped human declassification.
Highlights
- 2D epistemic security lattice (
src/lattice.rs): Combines Biba integrity and Bell-LaPadula confidentiality as(Trusted ⊏ SemiTrusted ⊏ Untrusted) × (Public ⊏ Internal ⊏ Confidential). Labels combine with a monotonic join (⊔), the lattice laws are tested exhaustively, and the engine detects the Lethal Trifecta: private data + untrusted content + external egress. - HTTP / MCP / A2A wire proxy (
src/proxy.rs,src/evaluator.rs): Inspects MCP JSON-RPC 2.0 requests, including batch arrays, and fails closed on encoded, malformed, or unknown methods. The proxy also:- Blocks control-plane writes that violate Biba integrity
- Locks down egress when the Lethal Trifecta is present
- Detects query-string and path exfiltration
- Guards external origins against SSRF (loopback, IMDS, RFC 1918, ULA, CGNAT)
- Guards against CL/TE request smuggling and Slowloris
- Cross-agent provenance (
src/provenance.rs): Stamps domain-separated HMAC-SHA256X-NetDIFT-Provenanceheaders in both directions, with hop limits, so taint passes across agent-to-agent delegation. Forged headers fail closed, which stops multi-agent "taint-laundering" worms. - Human declassification:
X-NetDIFT-Declassifytokens are single-use and nonce-tracked. Each token is bound to a segment-bounded method, host, and path scope plus an MCP tool. Using a token never resets the session's taint. - UDP DNS entropy guard (
src/dns.rs): Parses RFC 1035 queries and returnsRCODE=5 REFUSEDfor high-entropy or multi-label-split tunneling and for DNS egress that is not allowlisted under the Lethal Trifecta. It tracks the high-water taint label across active HTTP sessions. - Forensics and SIEM (
src/report.rs): Writes Elastic Common Schema (ECS v8.11.0) JSONL with0600permissions and produces a standalone dark-mode HTML forensic report with no CDN dependencies. A hardened loopback Admin Web Console runs at127.0.0.1:8091. It enforces a strict CSP and DNS-rebinding Host/Origin guards, and uses constant-time admin-token auth onPOST /api/declassify. - Single-binary CLI: Subcommands are
serve,demo(an 8-step live red-team containment run over real loopback TCP/UDP sockets),bench,declassify, andverify-provenance.
Reproducible Benchmark Summary (netdift bench --sessions 10, --release)
| Metric | Result |
|---|---|
| Clean-agent false positive rate | 0.0% |
| Attack containment recall | 100.0% |
| Mean wire overhead | ~5.9 µs/req |
| LLM judge spend | $0.00 |
Assets
| Platform | Archive |
|---|---|
| Linux x86_64 (static musl) | netdift-v0.1.0-x86_64-unknown-linux-musl.tar.gz |
| Linux aarch64 (static musl) | netdift-v0.1.0-aarch64-unknown-linux-musl.tar.gz |
| macOS Intel | netdift-v0.1.0-x86_64-apple-darwin.tar.gz |
| macOS Apple Silicon | netdift-v0.1.0-aarch64-apple-darwin.tar.gz |
| Windows x86_64 | netdift-v0.1.0-x86_64-pc-windows-msvc.zip |
Each archive contains the netdift binary, README.md, LICENSE, CHANGELOG.md, SECURITY.md, and policies/default_policy.yaml. Verify downloads with:
sha256sum -c SHA256SUMS.txt --ignore-missingVerification
- An independent security audit was run, and all Critical, High, Medium, and Low findings were fixed before release.
- 38 unit/integration tests pass. CI on stable Rust runs
rustfmt,clippy --all-targets -D warnings,cargo test, and smoke tests of the--releasedemo and benchmark. - Release binaries are built on native GitHub-hosted runners with stable Rust (
--locked), and each native binary is smoke-tested before it is attached.
Part of the Defensive AI-Security Suite
| Project | Layer |
|---|---|
| OodaTap | Behavioral detection of hybrid human+agent attacks |
| MirageGate | Cost-asymmetry tarpit and cryptographic human-handoff attribution |
| NetDIFT | Information-flow containment for internal AI agents |