Apache APISIX: the body_schema check in request-validation plugin can be bypassed
Key facts
- Attack vector
- Network
- Privileges required
- None
- User interaction
- None
- Attack complexity
- Low
- Impact type
- —
- Confidentiality · integrity · availability
- High · High · High
- Fix status
- No fix listed
Attack profile from CVSS 3.1 · NVD. Fix status from CNA.
Summary
In Apache APISIX before 2.13.0, when decoding JSON with duplicate keys, lua-cjson will choose the last occurred value as the result. By passing a JSON with a duplicate key, the attacker can bypass the body_schema validation in the request-validation plugin. For example, `{"string_payload":"bad","string_payload":"good"}` can be used to hide the "bad" input. Systems satisfy three conditions below are affected by this attack: 1. use body_schema validation in the request-validation plugin 2. upstream application uses a special JSON library that chooses the first occurred value, like jsoniter or gojay 3. upstream application does not validate the input anymore. The fix in APISIX is to re-encode the validated JSON input back into the request body at the side of APISIX. Improper Input Validation vulnerability in __COMPONENT__ of Apache APISIX allows an attacker to __IMPACT__. This issue affects Apache APISIX Apache APISIX version 2.12.1 and prior versions.
Why it matters now
SSVC decision points
Not available: CISA has not published SSVC decision points for this record.
Affected products
Remediation
No fixed version listed by the sources yet.
Timeline
- 2026-10-02 Threatist record created from CVE-2022-25757
- 2026-10-03 Alias added: GHSA-9xhv-qfpf-p2xx
References
More Apache Apisix vulnerabilities
- TI-2022-08057 apisix/batch-requests plugin allows overwriting the X-REAL-IP header KEVCVSS 3.1CRITICAL 9.8
- TI-2023-23979 The HTTP/2 protocol allows a denial of service (server resource consumption) because… KEVCVSS 3.1HIGH 7.5
- TI-2020-10921 In Apache APISIX, the user enabled the Admin API and deleted the Admin API access IP… CVSS 3.1MEDIUM 6.5
- TI-2026-24457 Apache APISIX: forward auth plugin allows header injection CVSS 3.1CRITICAL 9.1
- TI-2021-19447 Path traversal in request_uri variable CVSS 3.1HIGH 7.5
- TI-2026-52703 Apache APISIX: Unauthenticated CPU-exhaustion DoS CVSS 4.0HIGH 8.7
Sources
- CVE-2022-25757 · CVE Program
- CVE-2022-25757 · NVD
- FIRST EPSS
- GHSA-9xhv-qfpf-p2xx · GitHub Advisory Database · CC BY 4.0
This product uses the NVD API but is not endorsed or certified by the NVD. Sources and licences