graphql-security
Skill20 starsChanged 4 months agoMITView on GitHub
Detects GraphQL schemas without depth limits, cost analysis, or introspection
3 other projects use a version of this.
Adopted by
Most recently taken up by
- awarexone/AXguardtheir own version, first seen Sep 15, 2026
- deangrant/agentstheir own version, first seen Aug 16, 2026
- ShieldNet-360/secure-vibetheir own version, first seen Jul 9, 2026
Other versions3 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 3
- ShieldNet-360/secure-vibe★ 22same name
- awarexone/AXguard★ 18same name
- deangrant/agents★ 0same name
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
In this repository52 other files it gives its agents.
- CLAUDE.mdCLAUDE.md
- authentication-failuresSkill
- broken-access-controlSkill
- concurrency-correctnessSkill
- contract-reviewSkill
- cryptographic-failuresSkill
- crypto-library-misuseSkill
- csrfSkill
- exceptional-conditionsSkill
- excessive-agencySkill
- file-uploadSkill
- hardcoded-secretsSkill
- header-injectionSkill
- hotspotsSkill
- injectionSkill
- insecure-designSkill
- insecure-local-storageSkill
- insecure-output-handlingSkill
- insecure-plugin-designSkill
- integrity-failuresSkill
- ipc-securitySkill
- llm-supply-chainSkill
- logging-failuresSkill
- mass-assignmentSkill
- mcp-securitySkill
- memory-api-misuseSkill
- model-dosSkill
- model-theftSkill
- multi-agent-trustSkill
- nosql-injectionSkill
- numeric-trust-boundarySkill
- oauth-implementationSkill
- open-redirectSkill
- overrelianceSkill
- path-traversalSkill
- privilege-handlingSkill
- prompt-injectionSkill
- prototype-pollutionSkill
- pr-reviewSkill
- race-conditionSkill
- rag-securitySkill
- redosSkill
- security-cleanupSkill
- security-misconfigurationSkill
- security-reviewSkill
- sensitive-disclosureSkill
- ssrfSkill
- supply-chainSkill
- threat-modelSkill
- token-smugglingSkill
- training-data-poisoningSkill
- unsafe-api-consumptionSkill
The file
Files
GraphQL Security Check (CWE-400)
What this checks
Protects against GraphQL-specific attack vectors: unbounded query depth that causes exponential resolver execution, introspection left enabled in production (exposing the full schema to attackers), and batch/alias attacks that bypass rate limiting.
Vulnerable patterns
- GraphQL server constructed with no depth-limit or cost-analysis validation rule
- Deeply nested query allowed because no maximum-depth rule rejects it before resolver execution
- Alias batching that repeats a credential-accepting field many times in one request, bypassing per-HTTP-request rate limits
- Introspection left enabled in production, exposing the full schema to unauthenticated callers
Fix immediately
Flag the vulnerable code and explain the risk. Translate the principles below to the language and framework of the audited file — use that stack's documented validation rule, plugin, or middleware API; do not roll your own.
For each finding, establish these properties:
- Query depth is capped at a small fixed value (typically 5–10) by a validation rule or middleware that runs before resolver execution. Unbounded depth lets a single query trigger exponential resolver work.
- Total query cost is bounded. Either a cost-analysis layer that assigns weights to fields and rejects over-budget queries, or alias/field-count limits — the goal is that a single request cannot do unbounded work regardless of depth. Alias batching bypasses per-request rate limits unless this is enforced.
- Introspection is disabled in production. Leaving it on exposes the full schema — including deprecated fields, admin types, and hints for targeted attacks — to anyone who can hit the endpoint. Gate it on an environment flag.
- Every credential-accepting mutation (login, passwordReset, mfaVerify) has
a rate limit that survives alias batching — apply per operation, not per
HTTP request, so a thousand aliased
loginselections count as a thousand attempts.
Verification
- Query depth is limited to a fixed maximum (typically 5-10) via a validation rule or middleware
- Introspection is disabled in production environments
- Batch/alias attacks are mitigated by cost analysis, alias limits, or per-operation rate limiting
References
- CWE-400 (Uncontrolled Resource Consumption)
- CWE-200 (Exposure of Sensitive Information)
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

