Known exploited vulnerability

CVE-2024-36401

criticalCVSS 3.1 9.8In CISA KEVEPSS 100%Published · geoserver

The short answer

CVE-2024-36401 affects geoserver geoserver and is rated critical (CVSS 9.8). CISA added it to the Known Exploited Vulnerabilities catalog on 2024-07-15: attackers are using it, so patch it first. Fixed versions are published for gs-web-app (2.24.4, 2.25.2, 2.23.6) and gs-wfs (2.24.4, 2.25.2, 2.23.6).

What it is

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.

Weakness: CWE-95, CWE-94.

Severity

9.8 critical

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

Exploited (CISA KEV)

Yes, since Jul 15, 2024

Federal due date Aug 5, 2024

EPSS, next 30 days

100%

Higher than 100% of scored CVEs

How it can be exploited

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality impact
High
Integrity impact
High
Availability impact
High

What CISA says to do

Apply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable.

Affected packages and fixed versions

PackageEcosystemFixed inAdvisory
org.geoserver.web:gs-web-appMaven2.24.4, 2.25.2, 2.23.6, 2.22.6GHSA-6jj6-gm7p-fcvv
org.geoserver:gs-wfsMaven2.24.4, 2.25.2, 2.23.6, 2.22.6GHSA-6jj6-gm7p-fcvv
org.geoserver:gs-wmsMaven2.24.4, 2.25.2, 2.23.6, 2.22.6GHSA-6jj6-gm7p-fcvv

Is it in your code? Drop your lockfile into the free vulnerability check, or let vulnerability watch check your repository every day and open the upgrade as a pull request.

Affected products

geoserver. NVD's record lists the exact affected versions.

References

Questions

Is CVE-2024-36401 being exploited?

Yes. CISA added CVE-2024-36401 to its Known Exploited Vulnerabilities catalog on 2024-07-15, with a federal remediation due date of 2024-08-05.

How do I fix CVE-2024-36401?

Upgrade to a fixed version: org.geoserver.web:gs-web-app (Maven) 2.24.4 or 2.25.2 or 2.23.6 or 2.22.6; org.geoserver:gs-wfs (Maven) 2.24.4 or 2.25.2 or 2.23.6 or 2.22.6; org.geoserver:gs-wms (Maven) 2.24.4 or 2.25.2 or 2.23.6 or 2.22.6. CISA's required action: Apply mitigations per vendor instructions or discontinue use of the product if mitigations are unavailable.

From NVD, CISA KEV, FIRST EPSS and OSV.dev, checked . Status on NVD: Analyzed. The description is NVD's text, quoted as published.

Related

Know the day a CVE lands in your code

Connect a GitHub repository and ZeusQA checks its dependencies daily, briefs each advisory and opens the fix. Three test runs free, no card.