nuclei-templates/misconfiguration/graphql/graphql-array-batching.yaml

40 lines
1.2 KiB
YAML
Raw Normal View History

id: graphql-array-batching
2022-03-08 19:03:10 +00:00
info:
name: GraphQL Array-based Batching
author: Dolev Farhi
severity: low
description: |
Some GraphQL engines support batching of multiple queries into a single request. This allows users to request multiple objects or multiple instances of objects efficiently.
However, an attacker can leverage this feature to evade many security measures, including Rate Limit.
reference:
- https://stackoverflow.com/questions/62421352/graphql-difference-between-using-alias-versus-multiple-query-objects-when-doin
- https://github.com/dolevf/Damn-Vulnerable-GraphQL-Application
- https://graphql.security/
remediation: |
Deactivate or limit Batching in your GraphQL engine.
2022-03-08 19:03:10 +00:00
tags: graphql
requests:
- raw:
- |
POST /graphql HTTP/1.1
Host: {{Hostname}}
Content-Type: application/json
[{"query":"query {\n __typename \n }"}, {"query":"mutation { \n __typename \n }"}]
matchers-condition: and
2022-03-08 19:03:10 +00:00
matchers:
- type: word
2022-03-09 12:57:29 +00:00
part: body
2022-03-08 19:03:10 +00:00
words:
- ':"Query"'
- ':"Mutations"'
case-insensitive: true
condition: and
- type: word
part: header
words:
- "application/json"