Prompt Injection CTF
Hands-on AI security training. Explore 16 LLM security missions and 30 agentic security missions, study why an attack worked, then switch to defender mode and inspect the control that stops it.


Play now · Agentic Security Lab · Browse all 16 challenges · Propose a challenge
No signup or API key for the default practice mode. Live-model grading is optional and uses your own provider key.
Used in independent research: Can GPT Still Be Fooled? froze 11 of this CTF's system prompts into a regression benchmark: 18 attacks, 3 attempts each, across 9 GPT snapshots. Attack success fell from 54/54 on GPT-3.5 Turbo to 6/54 on GPT-5.6 Sol, and never reached zero.
If this helps you understand how AI systems fail, star the repo so more people find it.
What you attack
- Prompt injection, jailbreaks, token smuggling, and system prompt extraction
- Indirect injection, zero-click data exfiltration, and unsafe output handling
- AI agent tool abuse, excessive agency, and unbounded consumption
- RAG poisoning, misinformation, model poisoning, and supply-chain attacks
- Every risk in the OWASP Top 10 for LLM Applications 2025
Each challenge gives you a constrained AI, a concrete objective, instant feedback, and the defensive control behind the failure. The challenge-to-OWASP mapping is machine-readable and regression-tested.
| Track | What you get |
|---|
| Attack | Craft the prompt that crosses the system boundary |
| Explain | See the technique, impact, and detection signals |
| Defend | Inspect the guardrail code that blocks the attack |
| Compete | Earn points, unlock badges, and climb the leaderboard |
See the complete challenge gallery for goals, difficulty, points, OWASP mappings, and learning resources.
Agentic Security Lab
Open /agentic for three missions in each of the OWASP Agentic Top 10 categories for 2026. The 26 attacker missions cover goal hijacks, tool and identity abuse, supply-chain changes, virtual code execution, persisted memory, signed handoffs, cascading workflows, and misleading approval requests. Four defender missions require correct approval decisions or containment controls while preserving legitimate work.
- Scripted practice executes explicit JSON tool programs against fresh mock resources. It is unranked and does not measure a model's susceptibility to natural-language injection.
- Ranked attacker runs require verified Google sign-in, Firebase Admin configuration, and a server-side OpenAI or Anthropic key. Model claims never earn credit; committed tool effects determine the result.
- Ranked defender runs use deterministic server evaluation and require verified sign-in and Firebase. No model key is needed.
- Defense replay applies controls to the same tool requests. A separate legitimate task must still complete; memory attacks also require a safe clean follow-up in live mode.
- Code missions interpret at most 16 virtual JSON operations. They never execute host code, shells, real filesystem operations, or network requests.
- Each run permits eight tool calls, four model turns per stage, and a shared 45-second live deadline. Ranked runs have a per-user active lease and ten-run-per-minute limit.
- Foundation, Advanced, and Expert missions award 150, 300, and 500 points once per scenario version. Practice progress stays on the device; ranked progress is server-owned. Agentic and LLM boards remain separate, with an Overall board combining matching server user IDs. AISYWLC retains its original 16-mission cohort.
The acceptance suite covers every authored winning tool fixture, defense replay, legitimate controls, resets, stage isolation, schema forgery, manifest integrity, signed-message replay, virtual interpreter boundaries, and defender deny-everything failures. Real-provider difficulty and natural-language solve rates require separate live calibration; mocked-provider checks do not establish those rates.
Roadmap
Planned tracks, tracking how AI systems are actually being deployed. Ideas are not commitments; propose or vote on one.
Coding agents
- Malicious repo instructions: poisoned
AGENTS.md, CLAUDE.md, .cursorrules, and README text that hijack an agent on clone
- Prompt injection through issues, pull request descriptions, code comments, and CI logs
- Dependency attacks: slopsquatting (hallucinated package names), typosquats, and malicious install scripts
- Secret exfiltration from
.env files, git history, and shell environment
- Unsafe auto-approve: command allowlist bypasses, chained shell commands, and approval-fatigue prompts
- Poisoned tool configs: malicious MCP servers, rug-pulled tool descriptions, and hook or settings file tampering
- CI/CD agent abuse: over-privileged tokens, workflow injection, and agent-authored commits that pass review
Sandboxing and containment
- Sandbox escape missions: path traversal, symlink and mount tricks, and writable config outside the workspace
- Network egress control: DNS and allowlisted-domain exfiltration, and redirects through trusted hosts
- Credential isolation: leaked cloud metadata, mounted tokens, and over-broad service accounts
- Resource abuse: fork bombs, disk fill, and runaway spend against quotas and kill switches
- Defender missions: write the policy (filesystem, network, syscall, and permission scopes) that blocks the escape without breaking the legitimate task
- Mock-only by design: all execution stays in the virtual interpreter and never touches the host
Other emerging areas
- MCP and tool-ecosystem security: tool poisoning, cross-server shadowing, and confused-deputy OAuth flows
- Browser and computer-use agents: hidden-text injection, clickjacking, and credential-form lures
- Multimodal injection: instructions hidden in images, PDFs, audio, and screenshots
- Agent-to-agent protocols: spoofed agent cards, delegation abuse, and trust-chain confusion
- Long-term memory and personalization poisoning across sessions
- Reasoning-model attacks: chain-of-thought manipulation and judge or grader subversion
- Guardrail and classifier evasion for defender-mode scoring
- Live-model calibration of agentic difficulty and published solve rates
- Team and classroom modes with private leaderboards
- Exportable mission packs for workshops and internal training
- Benchmark mode to re-run missions against new model snapshots
Run it locally
Requires Node.js 22 or newer.