Content type
Description
The Content-Type header is not set to application/json. GraphQL APIs should always return a JSON response, according to the GraphQL specification.
Remediation
Ensure that the Content-Type header is set to application/json.
GraphQL Specific
Apollo
Yoga
Awsappsync
Graphqlgo
Graphqlruby
Hasura
Configuration
Identifier:
protocol/graphql_content_type
Examples
Ignore this check
checks:
protocol/graphql_content_type:
skip: true
Score
- Escape Severity: LOW
Compliance
OWASP: API7:2023
pci: 6.5.1
gdpr: Article-5
soc2: CC6
psd2: Article-97
iso27001: A.14.1
nist: SP800-95
fedramp: SC-7
Classification
- CWE: 16
Score
- CVSS_VECTOR: AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:L/A:N
- CVSS_SCORE: 4.3