MCP-Bastion 4.0.0

MCP-Bastion Documentation

Attack demos (GIFs)

Scripted GIF videos (terminal-style) plus runnable Python scenarios so users see Bastion value for each hero feature: attack → intercept → block/redact → how it helps you.

Related Link
Documentation bible DOCUMENTATION_BIBLE.md
Issue → solution → benefits (+ embedded GIFs) FEATURE_DEEP_DIVE.md
Narrative attacks ATTACK_PREVENTION.md
Multi-language MULTI_LANGUAGE_SUITE.md

Master tour (GIF)

Attack defense tour

Each clip is 4 beats: 1 ATTACK2 BASTION3 BLOCKED/REDACTED4 VALUE.

python scripts/generate_attack_demo_gifs.py   # regenerate GIFs
PYTHONPATH=src python -m examples.attack_demos --strict   # live scripted demos

Quick run (live, same scenarios)

## Windows PowerShell
$env:PYTHONPATH="src"; python -m examples.attack_demos

## Linux / macOS
PYTHONPATH=src python -m examples.attack_demos

PYTHONPATH=src python -m examples.attack_demos --only rate_limit
PYTHONPATH=src python -m examples.attack_demos --strict

Optional deps for full prompt/PII fidelity: torch, transformers, presidio-analyzer, en_core_web_sm.


01 — Prompt injection (prompt_guard) → -32001

Prompt guard

PYTHONPATH=src python -m examples.attack_demos --only prompt_guard

02 — PII leakage (pii) → redacted

PII

PYTHONPATH=src python -m examples.attack_demos --only pii

03 — Rate / denial of wallet (rate_limit) → -32002

Rate limit

PYTHONPATH=src python -m examples.attack_demos --only rate_limit

04 — Path traversal (content_filter) → -32005

Content filter

PYTHONPATH=src python -m examples.attack_demos --only content_filter

05 — Unauthorized tool (rbac) → -32006

RBAC

PYTHONPATH=src python -m examples.attack_demos --only rbac

06 — Schema bypass (schema_validation) → -32007

Schema

PYTHONPATH=src python -m examples.attack_demos --only schema

07 — Replay (replay_guard) → -32008

Replay

PYTHONPATH=src python -m examples.attack_demos --only replay

08 — Cost overrun (cost_tracker) → -32009

Cost

PYTHONPATH=src python -m examples.attack_demos --only cost

Dashboard (runtime view of the same defenses)

Dashboard tour

mcp-bastion dashboard --demo
## optional recapture:
## python scripts/capture_dashboard_demo.py

See dashboard/README.md and the Documentation bible.


Hero table

ID Feature Attack Defense GIF
01 prompt_guard Jailbreak in args -32001 gif
02 pii SSN/email in output Redact gif
03 rate_limit Agent loop -32002 gif
04 content_filter /etc/passwd -32005 gif
05 rbac viewer→write -32006 gif
06 schema_validation Bad args -32007 gif
07 replay_guard Dup nonce -32008 gif
08 cost_tracker Over budget -32009 gif

Extending

  1. Add scenario in examples/attack_demos/scenarios.py.
  2. Add storyboard entry in scripts/generate_attack_demo_gifs.py.
  3. Re-run generators; link from DOCUMENTATION_BIBLE.md.