# GraphQL Authorization Flaws > Access-control failures specific to GraphQL's shape: the check lives on one resolver path, not on the object, so the same data or action stays reachable through another field, edge, interface, aggregate, mutation payload or library-level directive bug. ## How it works GraphQL has no per-URL boundary to hang authorization on, and the spec defines none. Every field is a resolver, and an object is typically reachable many ways: ```text Query.invoice(id) -> Invoice Query.node(id) -> Node (via Node) # Relay global object ID Query.search(term) -> SearchResult (via union) User.invoices(first) -> Invoice # reachable from any User, e.g. invoice.owner SendInvoicePayload.invoice -> Invoice # mutation payloads are read paths too ``` A check written into `invoice(id:)` has to be copied into every other entry point; when copies drift, data depends on path. Relay IDs are not secrets: `graphql-relay-js` `toGlobalId` is base64 of `Type:id`, so `SW52b2ljZToxMDQy` is `Invoice:1042`. ### Failure taxonomy | Pattern | Example | |---|---| | Root-only enforcement, no check on traversal | Nautobot GHSA-mfwj-pjgx-22v2: `view_location` users pulled Device fields through a Location query (fixed v2.4.38 / v3.2.0) | | Alternate entry point | `node(id:)`, search unions, aggregates, `prev`/`next` siblings | | Field-level / argument-level gap | `revokeScope(userId:)` checked same-org targets only; cross-org it never ran (tenant permission tampering) | | Trusting identity from arguments | Praetorian: `brassCheckAccess(username, role)` returned `is_authorized` for whatever username the client sent → swap in an admin's | | Authenticated ≠ authorized mutations | Lab `setRole` checked login, not admin; Snapchat `deleteStorySnaps(ids:)` deleted anyone's Spotlight content ($15,000, H1 #1819832) | | Missing authentication on critical mutation | Prime CMS CVE-2026-129941: `createUser` on `/prime/graphql` with `isAuthenticated()` commented out and admin roles hard-coded in `createAbility()` | | Scope/schema boundary bypass | Craft CMS GHSA-xpg7-m6gm-4xfh (<5.11.2): anonymous client hops `prev`/`next` from one in-scope entry into sections withheld from the public schema, reading full custom-field content | | Shared cache ignoring identity | Kong `graphql-proxy-cache-advanced` CVE-2026-92442: cache key omits caller identity, one user's response served to another | | Batched-context confusion | Hive Gateway batch-execute authz bypass (see [[GraphQL Batching Attacks]]) | ### Library and directive bugs Declarative authz moves the bug into the framework — worth fingerprinting the engine (graphw00f) and checking versions: - **graphql-ruby GHSL-2026-152** — in `Execution::Next`, `Schema::Resolver#call` rescued `GraphQL::UnauthorizedError` from `authorized?` and set `is_authed = true`, so `resolve` ran and returned data / executed mutations (fixed 2.6.6). Related: GHSA-q3cc-p5hm-55wj (legacy interpreter rendered the original object when `Schema.unauthorized_object` handled the error), GHSA-4rw8-495r-pf6j (`Execution::Next`, fixed 2.6.14), and class-level `.authorized?` skipped on resolvers/mutations. - **@neo4j/graphql** — multi-condition `@authentication` JWT filters in generic syntax evaluated only the first condition (CVE-2026-92683, fixed 7.6.7; workaround explicit `AND` array or `roles_INCLUDES`); field-level `@authentication` silently dropped when a type-level rule exists (fixed 7.6.0 / 5.12.15); `@authentication` not enforced on top-level `@cypher` fields; aggregation queries bypass `@authentication` (CVE-2026-92684, fixed 7.6.8 / 5.12.17). Subscription transport bug in [[GraphQL Subscription Security]]. - **Drupal graphql_core_schema CVE-2026-126725 (SA-CONTRIB-2026-316)** — with the User Login extension enabled, anyone able to view an account could change its password, admins included (fixed 1.0.29). ## Testing 1. Get the schema ([[GraphQL Introspection]]) and list every path to each sensitive type: graphql-path-enum, or a short script over `possibleTypes` of interfaces/unions plus mutation payload types. 2. Build an authorization matrix with two tenants and two roles; test each path, each field, each mutation argument that names a principal or object. 3. Use aliases to fire all paths for one object in one request, so the response shows which resolver leaks. 4. Read `data`, not the status code: GraphQL errors ride in HTTP 200, and denied fields return `null` alongside errors. 5. Automate replay: GraphQLer's dual-profile chain replay for IDOR; Autorize-style tooling via [[Authorization Testing Automation]]. 6. Check aggregates, counts, connection filters and ordering as oracles (WPGraphQL ≤2.26.0 comment filters leaked commenter emails/IPs and existence of drafts). ## Notable cases - **FinTech platform (Salt Labs)** — `/BFF/graphql/mutation/doPayment` accepted a victim UID → unauthorized transfers; `receiptUrl` returned an unauthenticated third-party PDF link exposing PII. - **Airline booking API** — predictable integer IDs and no backend checks allowed mass read/modify of passenger PII and itineraries. - **Mass ATO, 29,000 accounts** — `tokenForgotPasswords` returned reset tokens with no authz. - **GitLab CVE-2021-4191** — unauthenticated user enumeration over `/api/graphql`. - **WPGraphQL** — Author/Contributor IDOR reading sensitive data. ## Defenses - Put authorization in the business/data layer that every resolver calls, not in individual resolvers (graphql.org guidance); then edges, `node`, aggregates and payloads inherit it. - Never derive identity from arguments; take it from the verified context (Apollo: populate `contextValue` from the token, enforce schema-wide in context and field-level in resolvers; GraphOS `@authenticated` / `@requiresScopes`). - Removing `node`/`nodes` shrinks surface but is not authorization. - Cache keys must include principal; regression-test each directive combination you rely on. ## Related - [[GraphQL Security]] - [[Broken Access Control]] - [[BOLA in APIs]] - [[Insecure Direct Object Reference]] - [[Function Level Authorization]] - [[Multi-Tenant Isolation]] - [[Authorization Testing Automation]] - [[GraphQL Introspection]] ## Sources - [[raw/dev.to/graphql-bola-one-object-many-paths-and-how-to-prove-the-gap-14345|GraphQL BOLA: one object, many paths, and how to prove the gap]] - [[raw/github.com/nautobot-object-view-permissions-bypass-via-graphql-traversal-13551|Nautobot object view permissions bypass via GraphQL traversal]] - [[raw/medium.com/allowed-to-view-the-location-handed-the-device-a-graphql-permission-ga-13726|Allowed to view the Location, handed the Device: a GraphQL permission gap in Nautobot…]] - [[raw/securitylab.github.com/ghsl-2026-152-privilege-escalation-via-authorization-bypass-in-graphql-13196|GHSL-2026-152: privilege escalation via authorization bypass in graphql-ruby]] - [[raw/rubysec.com/graphql-ruby-renders-results-from-objects-whose-authorized-checks-fail-12762|graphql-ruby renders results from objects whose authorized? checks failed]] - [[raw/daily.dev/graphql-ruby-execution-next-renders-objects-whose-authorized-check-fai-13385|graphql-ruby Execution::Next renders objects whose authorized check failed]] - [[raw/github.com/graphql-ruby-execution-next-skips-class-level-authorized-on-resolvers-15630|graphql-ruby: Execution::Next skips class-level authorized? on resolvers/mutations]] - [[raw/github.com/neo4j-graphql-only-the-first-condition-of-a-multi-condition-authentica-14044|@neo4j/graphql: only the first condition of a multi-condition @authentication JWT filter is evaluated]] - [[raw/github.com/neo4j-graphql-privilege-escalation-via-dropped-field-level-authenticat-13197|@neo4j/graphql privilege escalation via dropped field-level @authentication]] - [[raw/github.com/neo4j-graphql-authentication-not-enforced-on-top-level-cypher-fields-13554|Neo4j GraphQL @authentication not enforced on top-level @cypher fields]] - [[raw/github.com/neo4j-graphql-aggregation-queries-bypass-authentication-cve-2026-92684-14208|@neo4j/graphql aggregation queries bypass @authentication (CVE-2026-92684)]] - [[raw/github.com/craft-cms-5-0-0-before-5-11-2-graphql-schema-scope-bypass-via-prev-nex-14043|Craft CMS 5.0.0 before 5.11.2 GraphQL schema scope bypass via prev/next (critical)]] - [[raw/drupal.org/drupal-graphql-core-schema-critical-improper-authorization-password-ch-14351|Drupal GraphQL Core Schema critical improper authorization: password change account takeover]] - [[raw/critical.is/prime-cms-auth-bypass-via-createuser-graphql-mutation-cve-2026-129941-15322|Prime CMS auth bypass via createUser GraphQL mutation (CVE-2026-129941)]] - [[raw/github.com/kong-graphql-proxy-cache-advanced-leaks-cached-responses-across-caller-14783|Kong graphql-proxy-cache-advanced leaks cached responses across callers]] - [[raw/praetorian.com/exploiting-broken-authentication-control-in-graphql-4765|Exploiting Broken Authentication Control in GraphQL]] - [[raw/salt.security/api-threat-research-graphql-authorization-flaws-in-a-fintech-platform-4768|API Threat Research: GraphQL Authorization Flaws in a FinTech Platform]] - [[raw/oxo.is/delete-anyone-s-snapchat-spotlight-content-remotely-15-000-idor-via-gr-13720|Delete anyone's Snapchat Spotlight content remotely ($15,000 IDOR via GraphQL mutation)]] - [[raw/medium.com/the-mutation-everyone-tested-and-the-one-field-nobody-did-graphql-fiel-12760|The Mutation Everyone Tested, and the One Field Nobody Did: GraphQL Field-Level Authorization]] - [[raw/wiz.io/the-red-agent-pov-exploiting-broken-object-level-authorization-in-an-a-9944|The Red Agent POV: Exploiting Broken Object-Level Authorization in an Airline GraphQL API]] - [[raw/wpsec.com/wpgraphql-2-26-0-unauthenticated-info-exposure-via-comments-connection-13728|WPGraphQL = 2.26.0 unauthenticated info exposure via comments connection filters]] - [[raw/github.com/graphqler-context-aware-graphql-api-fuzzing-tool-4763|GraphQLer: Context-Aware GraphQL API Fuzzing Tool]] - [[raw/apollographql.com/apollo-authentication-and-authorization-docs-4400|Apollo Authentication and Authorization Docs]] - [[raw/cheatsheetseries.owasp.org/graphql-cheat-sheet-owasp-2815|GraphQL Cheat Sheet]]