CVE-2022-24112 — apisix
CRITICALCVE-2022-24112 is a critical-severity (CVSS 9.8) CWE-290 vulnerability. It is in CISA's Known Exploited Vulnerabilities catalog (added 2022-08-25) — treat it as actively exploited and patch now. A fix is available — see the affected versions and patch details below.
apisix/batch-requests plugin allows overwriting the X-REAL-IP header
Exploitation Status
Actively exploited in the wild
- Confirmed by CISA's Known Exploited Vulnerabilities catalog on 2022-08-25. Federal agencies were required to remediate by 2022-09-15.
- CISA assesses this as automatable — exploitation doesn’t require manual, per-target effort, which raises the odds of mass scanning and opportunistic attacks.
- A successful exploit gives an attacker total control of the affected component, not partial access.
Exploitation and automatability from CISA (KEV catalog and SSVC triage) for CVE-2022-24112.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
CVE-2022-24112 by exploitation likelihood (EPSS) against impact (CVSS). In the shaded patch-first corner (EPSS 50%+, CVSS 7.0+).
Where this sits among everything scored
Of 394,803 CVEs with a current EPSS score, this one falls in the ≥ 90% band (highlighted). Counts from FIRST.org, log-scaled.
Description
An attacker can abuse the batch-requests plugin to send requests to bypass the IP restriction of Admin API. A default configuration of Apache APISIX (with default API key) is vulnerable to remote code execution. When the admin key was changed or the port of Admin API was changed to a port different from the data panel, the impact is lower. But there is still a risk to bypass the IP restriction of Apache APISIX's data panel. There is a check in the batch-requests plugin which overrides the client IP with its real remote IP. But due to a bug in the code, this check can be bypassed.
Affected Products
apisixapacheResearch use only. For defensive security, authorized penetration testing, and academic research only. Never execute exploit code against systems without explicit written authorization.
Apache APISIX 2.12.1 - Remote Code Execution (RCE)
by Ven3xy · Mar 16, 2022
Detection & mitigation playbook
VulnerabilityDetect
Identify every host running the affected component and compare the installed build against the fixed version below — for source-built or distro-packaged software the version string, not a lockfile, is the source of truth (`dpkg -l`, `rpm -q`, or the binary's own `--version`).
Fix
Upgrade the affected component to the fixed release for CVE-2022-24112, or apply your distribution's backported patch — distro builds are often patched at an older version number, so check your vendor's advisory rather than the upstream version alone.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How to detect CVE-2022-24112
A community-maintained Nuclei template exists for this CVE. You can scan for it directly:
nuclei -id cve-2022-24112 -u https://target- Template
- Apache APISIX - Remote Code Execution
- Severity
- critical
- Impact
- Successful exploitation of this vulnerability could allow an attacker to execute arbitrary code on the affected system.
- Remediation
- Upgrade to 2.10.4 or 2.12.1. Or, explicitly configure the enabled plugins in `conf/config.yaml` and ensure `batch-requests` is disabled. (Or just comment out `batch-requests` in `conf/config-default.yaml`).
Template by ProjectDiscovery nuclei-templates (Mr-xn), MIT licensed. View the full template. Scan only systems you are authorised to test.
Frequently Asked Questions
Is CVE-2022-24112 in your dependencies?
Find it across , including transitive dependencies.