prompt-injection

prompt-injection is a skill for Claude Code, Codex from PurpleAILAB/Decepticon. It costs 55 tokens per session (1,389 once invoked), scanned A, original, Apache-2.0.

A security-testing playbook for finding prompt injection, where untrusted text tricks an AI system into ignoring its instructions, and tool-call hijacking in applications that use AI agents.

In plain words
What is it for?
It is for testing chatbots, retrieval systems, browser agents, code-review bots, and AI tools connected to email, CRM, or CI/CD systems.
Why use it?
It helps uncover paths from malicious content to unauthorized tool use, data theft, or code execution.

Skill for Claude CodeCodex

Written for no agent in particular: nothing here depends on one.

Good fit It is for testing chatbots, retrieval systems, browser agents, code-review bots, and AI tools connected to email, CRM, or CI/CD systems.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/purpleailab/decepticon/prompt-injection
About the project

Decepticon is an autonomous red-team agent that coordinates AI agents, security tools, sandboxes, and supporting services for authorized cybersecurity assessments. Security researchers and red teams can run it through its Docker stack, cloud service, command-line interface, or Python SDK, with the catalogue entries representing its available skills.

PurpleAILAB/Decepticon · 5,491 stars · on GitHub · decepticon.red

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add PurpleAILAB/Decepticon --skill prompt-injection
Clone the repo
git clone --depth 1 https://github.com/PurpleAILAB/Decepticon

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for prompt-injection

README.md
[![agentmods](https://agentmods.dev/badge/skills/purpleailab/decepticon/prompt-injection/github.svg)](https://agentmods.dev/skills/purpleailab/decepticon/prompt-injection)
Your own site
<a href="https://agentmods.dev/skills/purpleailab/decepticon/prompt-injection"><img src="https://agentmods.dev/badge/skills/purpleailab/decepticon/prompt-injection/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for prompt-injection

Your own site · 80×15
<a href="https://agentmods.dev/skills/purpleailab/decepticon/prompt-injection"><img src="https://agentmods.dev/badge/skills/purpleailab/decepticon/prompt-injection.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 55 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,389 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. ✓ AI security review Sonnet 5 · 6 Sept 2026 📄 Read the review Third-party audits
  • NVIDIA SkillSpector warn 7 Sept 2026
SkillSpector: 5 findings, up to high

These are SkillSpector’s own severities. On a checked sample its high-severity flags on skills were ~96% false positives — a documented command, a public API, a “never do X” rule — so we show them as a caution to read, not a verdict. Why →

  • high YARA Match · line 3
    YARA rule matched a hack tool or exploit indicator (offensive tools, reconnaissance, privilege escalation, or exploit frameworks).
    Fix: Remove offensive tool references and exploit code. Legitimate agent skills should not contain penetration testing tools, exploit frameworks, or reconnaissance utilities.
  • high Prompt Injection · line 31
    This pattern attempts to override system instructions or ignore safety constraints. Without LLM analysis, manual review is recommended.
    Fix: Remove or rewrite any text that instructs the agent to ignore prompts, override safety rules, or trust unverified content. Ensure skill content cannot be injected to alter agent behavior.
  • high Prompt Injection · line 82
    Hidden instructions were detected in comments or invisible text. These could contain malicious directives. Manual review is recommended.
    Fix: Audit all comments and invisible characters. Remove any instructions that direct the agent to perform unauthorized actions. Use plain, reviewable content.
  • high Privilege Escalation · line 95
    Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
    Fix: Remove references to credential paths. Use environment variables or secrets managers. For docs, use placeholder paths (e.g., /path/to/config). Never load .env or token files in production code paths.
  • high Prompt Injection · line 100
    This pattern attempts to override system instructions or ignore safety constraints. Without LLM analysis, manual review is recommended.
    Fix: Remove or rewrite any text that instructs the agent to ignore prompts, override safety rules, or trust unverified content. Ensure skill content cannot be injected to alter agent behavior.
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00055 $0.01389
Opus 5 $0.00028 $0.00694
Sonnet 5 $0.00011 $0.00278
Haiku 4.5 $0.00006 $0.00139

Measured 8d ago against content hash 42290c61f36e, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

prompt-injection scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 8d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

Origin

Copies of this mod

1 near-identical copy found in the catalogue:

packages/decepticon/decepticon/skills/standard/analyst/prompt-injection/SKILL.md · 141 lines

How it starts

The opening of the file, as written. The whole thing — 141 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Prompt Injection Playbook

Every product shipping an LLM interface in 2026 has this surface. The bug bounty payouts are high because nobody has a clean defense, and the chain impact is unbounded (prompt injection → tool call → exfil → RCE in the agent's sandbox).

1. Target inventory — what counts as an LLM application

  • Chatbots with document upload / RAG
  • IDE copilots and code-review bots
  • Email assistants (classic indirect-injection vector)
  • Browser agents / AI-powered scraping tools
  • Customer support bots with CRM tool access
  • Agentic frameworks (LangChain, CrewAI, Semantic Kernel) running tools
  • CI/CD bots that read PR descriptions into a prompt
  • Internal "chat with your data" dashboards

2. Injection vectors

Direct

User-controlled chat input reaches the system prompt (or overrides it through role-play: "Ignore previous instructions and...").

Indirect (the real money)

Attacker-controlled content flows through a document the LLM later ingests:

  • PDF upload parsed by the LLM
  • Email body summarised by an assistant
  • Webpage scraped by a browser agent
  • Git diff read by a code-review bot
  • Slack message that a bot reads on trigger
  • RAG corpus poisoning (add a malicious document to the search index)

Tool-description injection

If tools are registered dynamically (plugin marketplace), a malicious plugin can supply a tool description that tricks the model into calling it.

3. Audit workflow

# Find LLM call sites
grep -rE 'openai|anthropic|bedrock|ollama|gemini|litellm' /workspace/src
grep -rE 'ChatOpenAI|ChatAnthropic|LLM\(|create_agent' /workspace/src

# Find prompt templates built from user input
grep -rE '(f"|f\x27|format\()[^"\x27]*\{(user|input|body|message|content|text)' /workspace/src

# Find tool definitions (LangChain @tool decorators, OpenAI tool_spec)
grep -rE '@tool|tools\s*=|function_calling|tool_choice' /workspace/src

For each tool definition, ask:

  1. Does the tool perform filesystem / network / shell / DB operations?
  2. What happens if the LLM calls it with attacker-chosen arguments?
  3. Is there a human-in-the-loop confirmation?

Read the full file on GitHub · 141 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 8d ago First seen · 141 lines · 55 tokens per session scan E 42290c61f36e

Subscribe to this mod's changes

prompt-injection is a skill published in the GitHub repository PurpleAILAB/Decepticon (5,491 stars, last pushed 12d ago), licensed Apache-2.0. It adds 55 tokens to every session and 1,389 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.