Six tools · one corpus · open source

The security stack for AI agents

Prompt injection and MCP supply-chain attacks are the new attack surface. Bastion gives you the full loop: scan, prevent, attack, investigate, and gate — all sharing one canonical injection corpus.

scan
prevent
attack

Every stage reads and writes the same policy format, so a finding in one tool hardens the next.

The suite

One tool for each stage of agent defense

Pre-flight MCP supply-chain scanner
pip install bastionsupply
  • Static analysis of an MCP server’s own tool definitions — no LLM, no network
  • Catches tool-poisoning, hidden-unicode & homoglyph names, tool-shadowing, secret solicitation
  • Rug-pull detection via lock / verify
v0.4.0 · MIT Details →

agentbastion

prevent
In-process firewall for AI agents
pip install agentbastion
  • Three guards in one SDK: inbound injection block, tool-call guard, outbound PII/secret redaction
  • Tool-call guard is the differentiator — stops mass email/delete/refund/exfil
  • Drop-in SDK: data never leaves your box; optional LLM judge
v0.9.0 · MIT Details →

bastionprobe

attack
Pentest / injection fuzzer
pip install bastionprobe
  • Focus on indirect prompt injection via tool output
  • Canary-token + forbidden-tool scoring; multi-run land-rate by tactic
  • Cross-model / cross-vendor matrix (Claude + GPT)
v0.17.0 · MIT Details →

bastiontrace

investigate
Trace forensics
pip install bastiontrace
  • Derives inject point → landing → causal path → blast radius from a JSONL trace
  • Verdicts: LANDED / ATTEMPTED / CLEAN
  • No LLM, no cloud — pure analysis
v0.2.0 · MIT Details →
Runtime MCP security gateway
pip install bastiongateway
  • Sits inline between agent and MCP servers (stdio + HTTP/SSE)
  • Drops poisoned tools, enforces allow/deny, blocks injected results, redacts PII in arguments
  • JSONL forensic log; consumes the policy bastionsupply harden emits
v0.7.0 · MIT Details →

bastioncorpus

corpus
Shared injection dataset
pip install bastioncorpus
  • 128 rows: 81 malicious payloads / 47 benign false-positive traps
  • 5 languages (en/it/de/fr/es), one taxonomy
  • Three format adapters: to_probe, to_semantic, to_trace
v0.2.1 · MIT Details →
Why Bastion

WAF and Burp Suite — for agents

Defense in depth

Static pre-flight scanning, in-process filtering, and an inline runtime gateway — layered, not a single choke point.

Runs on your box

Core detection is local and dependency-light. No data leaves your infrastructure; an LLM judge is opt-in.

Honest benchmarks

Measured against a shared, multilingual corpus with false-positive traps — recall and FPR published, not hand-waved.

Open core

Free to run. Pro to scale.

All six tools are open source and free forever. Bastion Pro unlocks the multi-tenant gateway, deep runtime inspection, and priority support.