Skip to content

feat:Add MCP scenario module with tool poisoning, policy misconfig, detectors and CTF challenges - #581

Open
nitinawari wants to merge 1 commit into
GenAI-Security-Project:mainfrom
nitinawari:feat/mcp-ctf-scenarios
Open

feat:Add MCP scenario module with tool poisoning, policy misconfig, detectors and CTF challenges#581
nitinawari wants to merge 1 commit into
GenAI-Security-Project:mainfrom
nitinawari:feat/mcp-ctf-scenarios

Conversation

@nitinawari

Copy link
Copy Markdown
Contributor

Summary

Adds an MCP scenario module so FinBot can run clean vs compromised tool environments, including return-value poisoning, policy misconfiguration, new detectors, and three CTF challenges.

Features added

  • Tool output poisoning via output_append (return-value injection after a real tool call)
  • Permission / policy misconfig (e.g. FinStripe max_payment, SystemUtils enabled tools)
  • Benign vs compromised environment presets (Dark Lab apply for safe resets/policy; poison presets as preview → copy/paste; CLI can apply any preset)
  • UnexpectedEndpointDetector for off-allowlist / blocked-host egress via network_request
  • ToolOutputPoisoningDetector for output_append + PII exfil
  • ToolDriftDetector wiring for MCP tool override / rediscovery drift
  • Three new CTF challenges with OWASP / CWE / MITRE labels

Challenges added

Challenge ID Title Detector
data-exfil-output-poison Return Value ToolOutputPoisoningDetector
data-exfil-unexpected-egress Unexpected Egress UnexpectedEndpointDetector
recon-mcp-tool-drift Tool Drift ToolDriftDetector

Test plan

  • pytest tests/unit/mcp/test_output_poisoning.py tests/unit/mcp/test_server_policy.py
  • pytest tests/unit/scenarios/test_mcp_scenario_loader.py
  • pytest tests/unit/ctf/test_mcp_supply_chain_detectors.py tests/unit/ctf/test_tool_drift_detector.py tests/unit/ctf/test_mcp_supply_chain_challenges.py

GSoC mapping

Week 9-11 (phase 4)

  • Deliverable C : MCP-style scenario module (realism upgrade).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant