auditing-graphql-attack-surface

Solid

Audit the attack surface a GraphQL API exposes that a plain endpoint does not: schema introspection left open, unbounded query depth and recursion, aliasing and field duplication that multiply cost, query batching that defeats rate limits and enables brute force, field-level authorization that a resolver skips even when the object check passed, and mutations reached without the guard their action needs. Covers the query and variables as the source, the resolver and the data or work it triggers as the sink, and the missing depth, cost, batch, or field guard as the bug. Use when reviewing a GraphQL schema, its resolvers, or a gateway that fronts one. Introspection and cost limits are one audit; per-field and per-mutation authorization is the other.

API & Backend 4 stars 1 forks Updated yesterday MIT

Install

View on GitHub

Quality Score: 80/100

Stars 20%
23
Recency 20%
100
Frontmatter 20%
70
Documentation 15%
100
Issue Health 10%
80
License 10%
100
Description 5%
100

Skill Content

# Auditing GraphQL attack surface: the schema is the map, the resolver is the guard A GraphQL API gives the client a query language over your data graph, and with it a set of failure modes a fixed endpoint never had. The client, not the server, decides the shape and depth of each request, so cost is client-controlled. The schema describes every type and field, so leaving introspection open hands an attacker the map. And authorization now lives per field and per resolver, so a check that held at the object level can be skipped one field deeper. Two audits sit here: the surface and cost audit (what the client can see and how expensive it can make a request), and the authorization audit (whether every field and mutation enforces the access its data needs). ## When to use - You are reviewing a GraphQL schema, its resolvers, or a gateway that fronts one. - The client controls query shape, depth, aliasing, or batching. - Authorization is enforced in resolvers, per field or per mutation, not only at a route. ## Scope check Audit a GraphQL surface only in systems you own or are authorized to test, with accounts across roles and tenants and permission to send shaped and batched queries. If you can't name the authorization, stop. ## The loop 1. **Recover the schema and the surface.** Determine what the client can learn: is introspection enabled, do field suggestions leak type names on error, is there a published schema? Recover the types, fields, and mutations reachable. T...

Details

Author
UnboundCompute
Repository
UnboundCompute/security-agent-skills
Created
5 days ago
Last Updated
yesterday
Language
N/A
License
MIT

Integrates with

Similar Skills

Semantically similar based on skill content — not just same category