CVE-2024-36401: OSGeo GeoServer GeoTools Eval Injection Vulnerability
Vulnerability summary
CVE-2024-36401 is a critical (CVSS 9.8) Eval Injection vulnerability in OSGeo GeoServer. It is known to be exploited: CISA lists it, first on 15-07-2024. EPSS estimates a 99.81% chance of exploitation in the next 30 days, higher than 99.9% of scored vulnerabilities. 4 public exploits are recorded.
Advisory lineage
Upstream 0 · Downstream 0 · Related 1Timeline
- 01-07-2024PublishedVulnerability first disclosed.
- 15-07-2024Added to CISA KEVOSGeo GeoServer GeoTools Eval Injection Vulnerability
- 05-08-2024CISA remediation dueApply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable.
- 21-10-2025Last modifiedVulnerability information updated.
Description
GeoServer is an open source server that allows users to share and edit geospatial data. Prior to versions 2.22.6, 2.23.6, 2.24.4, and 2.25.2, multiple OGC request parameters allow Remote Code Execution (RCE) by unauthenticated users through specially crafted input against a default GeoServer installation due to unsafely evaluating property names as XPath expressions. The GeoTools library API that GeoServer calls evaluates property/attribute names for feature types in a way that unsafely passes them to the commons-jxpath library which can execute arbitrary code when evaluating XPath expressions. This XPath evaluation is intended to be used only by complex feature types (i.e., Application Schema data stores) but is incorrectly being applied to simple feature types as well which makes this vulnerability apply to **ALL** GeoServer instances. No public PoC is provided but this vulnerability has been confirmed to be exploitable through WFS GetFeature, WFS GetPropertyValue, WMS GetMap, WMS GetFeatureInfo, WMS GetLegendGraphic and WPS Execute requests. This vulnerability can lead to executing arbitrary code. Versions 2.22.6, 2.23.6, 2.24.4, and 2.25.2 contain a patch for the issue. A workaround exists by removing the `gt-complex-x.y.jar` file from the GeoServer where `x.y` is the GeoTools version (e.g., `gt-complex-31.1.jar` if running GeoServer 2.25.1). This will remove the vulnerable code from GeoServer but may break some GeoServer functionality or prevent GeoServer from deploying if the gt-complex module is needed.
CVSS metrics
4 scores · 3 sources · 2 versions- OSV · MavenEcosystem advisory · calculated9.8CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H/E:H
- NVDNIST9.8CriticalCVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
EPSS trend
Probability
99.81%
Chance of exploitation in the next 30 days
Percentile
100%
Versus all other CVEs
30-day change
0.00 pp
From 99.81% on 20-09-2026
Known exploited
Compare KEV catalogs- Added
- 15-07-2024
- Federal due date
- 05-08-2024
CISA required action
Apply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable. nvd.nist.gov/vuln/detail/CVE-2024-36401
Public exploits
4 foundGeotools
Maturity: poc
Cve 2022 41852
Maturity: poc
Exploit Reference (vicarius.io)
Maturity: unknown
Weaknesses
CWE · root cause- CWE-95Improper Neutralization of Directives in Dynamically Evaluated Code ('Eval Injection')The product receives input from an upstream component, but it does not neutralize or incorrectly neutralizes code syntax before using the input in a dynamic evaluation call (e.g. "eval").
- CWE-94Improper Control of Generation of Code ('Code Injection')The product constructs all or part of a code segment using externally-influenced input from an upstream component, but it does not neutralize or incorrectly neutralizes special elements that could modify the syntax or behavior of the intended code segment.
Affected systems
Org.geoserver2 products
- gs-wfs≥ 2.24.0, < 2.24.4 | ≥ 2.25.0, < 2.25.2 | ≥ 2.23.0, < 2.23.6 | < 2.22.6
- gs-wms≥ 2.24.0, < 2.24.4 | ≥ 2.25.0, < 2.25.2 | ≥ 2.23.0, < 2.23.6 | < 2.22.6
Geoserver1 product
- geoserver< 2.22.6 | ≥ 2.23.0, < 2.23.6 | ≥ 2.24.0, < 2.24.4 | ≥ 2.25.0, < 2.25.2
Geotools1 product
- geotools< 29.6 | ≥ 30.1, < 30.4 | ≥ 31.1, < 31.2 | 30.0 | 30.0:rc | 31.0 | 31.0:rc
Org.geoserver.web1 product
- gs-web-app≥ 2.24.0, < 2.24.4 | ≥ 2.25.0, < 2.25.2 | ≥ 2.23.0, < 2.23.6 | < 2.22.6
4 vendors · 5 products
References
9 links- github.com/geoserver/geoserver/security/advisories/GHSA-6jj6-gm7p-fcvvX Refsource CONFIRMWEBMitigationVendor Advisory
- github.com/geotools/geotools/security/advisories/GHSA-w3pj-wh35-fq8wX Refsource MISCWEBExploitVendor Advisory
- www.cisa.gov/known-exploited-vulnerabilities-catalog?field_cve=CVE-2024-36401Government ResourceWEBUS Government Resource