sql-injection

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

A security-testing playbook for finding SQL injection, where untrusted input changes a database query instead of being treated as ordinary data.

In plain words
What is it for?
It is for tracing input through raw SQL, ORM escape hatches, query parameters, forms, headers, cookies, and message payloads across several programming languages.
Why use it?
It helps locate unsafe query construction that can expose, alter, or delete database records.

Skill for Claude CodeCodex

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

Good fit It is for tracing input through raw SQL, ORM escape hatches, query parameters, forms, headers, cookies, and message payloads across several programming languages.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/purpleailab/decepticon/sql-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,452 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 sql-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 sql-injection

README.md
[![agentmods](https://agentmods.dev/badge/skills/purpleailab/decepticon/sql-injection.svg)](https://agentmods.dev/skills/purpleailab/decepticon/sql-injection)
Your own site
<a href="https://agentmods.dev/skills/purpleailab/decepticon/sql-injection"><img src="https://agentmods.dev/badge/skills/purpleailab/decepticon/sql-injection.svg" alt="Measured on agentmods" height="20"></a>
Per session 47 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,360 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
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.00047 $0.01360
Opus 5 $0.00023 $0.00680
Sonnet 5 $0.00009 $0.00272
Haiku 4.5 $0.00005 $0.00136

Measured 4d ago against content hash 87731fd4aace, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-07, from the pricing page.

Security

Grade A, and why

sql-injection scanned grade A with 1 finding 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 4d 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.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl "https://target.com/search?q=1' AND SLEEP(5)-- -"
Origin

Copies of this mod

1 near-identical copy found in the catalogue:

packages/decepticon/decepticon/skills/standard/analyst/sql-injection/SKILL.md · 118 lines

How it starts

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

SQL Injection Hunting Playbook

Classic, still the king. Modern ORMs reduce the surface area but every codebase has escape hatches (raw queries, dynamic table names, LIKE fragments) where taint tracking pays off.

1. Sources

Anything accepting untrusted input: query params, form bodies, headers, cookies, JWT claims, file contents parsed as config, message-queue payloads.

2. Sinks by language/framework

Language Safe API Dangerous API
Python cursor.execute(sql, params) cursor.execute(f"... {user}"), %-format
Python SQLAlchemy text().bindparams text(f"... {user}"), raw_sql
Python Django ORM filter kwargs Model.objects.raw(...), .extra(where=[...])
Node pg.query(text, params) Template literals with user data
Node Prisma $queryRaw\...`` $queryRawUnsafe(userString)
Java PreparedStatement Statement.executeQuery(string + user)
Java JPA criteria entityManager.createNativeQuery(user + sql)
Go db.Query(text, args...) fmt.Sprintfdb.Query
Ruby Rails where("col = ?", x) where("col = '#{x}'"), find_by_sql(interp)
PHP PDO prepared mysqli_query($conn, $user . $sql)

3. Taint audit steps

# Semgrep covers 80% of obvious cases
semgrep --config p/sql-injection /workspace/src --sarif -o /workspace/sem-sqli.sarif
kg_ingest_sarif("/workspace/sem-sqli.sarif", "semgrep")

# Grep for the high-signal patterns semgrep misses (dynamic order/group by)
grep -rE 'ORDER BY.*\$|LIMIT.*\$|GROUP BY.*\$' /workspace/src
grep -rE 'execute\s*\(.*f["\']|execute\s*\(.*%.*%' /workspace/src

# Django raw + extra (scanner blind spot)
grep -rE '\.raw\(|\.extra\(' /workspace/src

# Second-order: anything that stores user input then queries by it unescaped
grep -rE 'INSERT INTO.*VALUES.*\?|UPDATE.*SET' /workspace/src

Read the full file on GitHub · 118 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. 4d ago First seen · 118 lines · 47 tokens per session scan A 87731fd4aace

Subscribe to this mod's changes

sql-injection is a skill published in the GitHub repository PurpleAILAB/Decepticon (5,452 stars, last pushed 8d ago), licensed Apache-2.0. It adds 47 tokens to every session and 1,360 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

optimizing-ef-core-queries

Optimize Entity Framework Core queries by fixing N+1 problems, choosing correct tracking modes, using compiled queries, and avoiding common performance traps. Use when EF Core queries are slow, generating excessive SQL, or causing high database load.

Harmeet10000/skills · 53 tokens

golang-database

Comprehensive guide for Go database access. Covers parameterized queries, struct scanning, NULLable column handling, error patterns, transactions, isolation levels, SELECT FOR UPDATE, connection pool, batch processing, context propagation, and migration tooling. Use this skill whenever writing, reviewing, or debugging…

Harmeet10000/skills · 116 tokens

postgresql-table-design

Design a PostgreSQL-specific schema. Covers best-practices, data types, indexing, constraints, performance patterns, and advanced features.

Harmeet10000/skills · 31 tokens

sql-optimization-patterns

Master SQL query optimization, indexing strategies, and EXPLAIN analysis to dramatically improve database performance and eliminate slow queries. Use when debugging slow queries, designing database schemas, or optimizing application performance.

Harmeet10000/skills · 44 tokens

query-writing

Writes and executes SQL queries from simple SELECTs to complex multi-table JOINs, aggregations, and subqueries. Use when the user asks to query a database, write SQL, run a SELECT statement, retrieve data, filter records, or generate reports from database tables.

langchain-ai/deepagents · 57 tokens

stale-sweep

Sweep the googleapis/mcp-toolbox repo for issues and PRs with no real activity in N days (default 60), sort each by whose silence it is (the author's, ours, or nobody's), and draft the nudge or close comment. Use whenever a maintainer asks for a stale sweep, backlog cleanup, or an SLO check, e.g. "stale sweep", "find…

googleapis/mcp-toolbox · 159 tokens