Vulnerability · Published Jul 2, 2024 · Assigned by GitHub_M

CVE-2024-36404GeoTools Remote Code Execution (RCE) vulnerability in evaluating XPath expressions

Critical 9.8

In plain English

A critical-severity security flaw in geotools from geotools. There are no confirmed reports of exploitation so far. The chance it is exploited in the next 30 days is estimated at 76.1% (higher than 99.5% of all known vulnerabilities). Ready-made attack tooling exists: Nuclei. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)9.8Critical
Exploit odds (30 days)76.1%top 0.5% of all CVEs
Exploited in the wildNo reportsCISA SSVC: none
Attack tooling1Nuclei

Official description

GeoTools is an open source Java library that provides tools for geospatial data. Prior to versions 31.2, 30.4, and 29.6, Remote Code Execution (RCE) is possible if an application uses certain GeoTools functionality to evaluate XPath expressions supplied by user input. Versions 31.2, 30.4, and 29.6 contain a fix for this issue. As a workaround, GeoTools can operate with reduced functionality by removing the `gt-complex` jar from one's application. As an example of the impact, application schema `datastore` would not function without the ability to use XPath expressions to query complex content. Alternatively, one may utilize a drop-in replacement GeoTools jar from SourceForge for versions 31.1, 30.3, 30.2, 29.2, 28.2, 27.5, 27.4, 26.7, 26.4, 25.2, and 24.0. These jars are for download only and are not available from maven central, intended to quickly provide a fix to affected applications.

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
Mavenorg.geotools.xsd:gt-xsd-core29.6GHSA-w3pj-wh35-fq8w
Mavenorg.geotools.xsd:gt-xsd-core31.2GHSA-w3pj-wh35-fq8w
Mavenorg.geotools.xsd:gt-xsd-core30.4GHSA-w3pj-wh35-fq8w
Mavenorg.geotools.xsd:gt-xsd-core28.6GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-app-schema29.6GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-app-schema31.2GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-app-schema30.4GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-app-schema28.6GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-complex31.2GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-complex30.4GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-complex28.6GHSA-w3pj-wh35-fq8w
Mavenorg.geotools:gt-complex29.6GHSA-w3pj-wh35-fq8w

Affected products (as reported)

VendorProductVersions
geotools geotools < 29.6>= 30.0, < 30.4>= 31.0, < 31.2

Weakness: CWE-95 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

References