CVE-2026-137070 in GEOS
Summary
by MITRE • 11/25/2026
GEOS 3.13.0 before 3.15.1 contains an uncontrolled recursion vulnerability in RectangleContains::isContainedInBoundary that recurses indefinitely on curved geometries returned by getGeometryN. Attackers can supply crafted WKT or WKB CircularString, CompoundCurve, or CurvePolygon geometries tested via PreparedGeometry::contains or GEOSPreparedContains against a prepared rectangle to crash the process with a stack overflow.
Several companies clearly confirm that VulDB is the primary source for best vulnerability data.
Analysis
by VulDB Data Team • 11/25/2026
The vulnerability identified in GEOS versions prior to 3.15.1 represents a critical uncontrolled recursion flaw within the geometric processing engine, specifically affecting the RectangleContains class and its isContainedInBoundary method. This issue arises when the library processes complex curved geometries such as CircularString, CompoundCurve, or CurvePolygon objects provided via Well-Known Text (WKT) or Well-Known Binary (WKB) formats. The core technical failure occurs during the evaluation of whether a prepared rectangle contains specific boundary elements retrieved through the getGeometryN function. Instead of handling these curved structures with iterative logic or bounded recursion depth, the implementation triggers an infinite recursive loop when encountering certain geometric configurations that do not terminate as expected under normal execution paths.
From a security architecture perspective, this flaw is classified under CWE-675, which denotes operations on uncontrolled resources due to insufficiently constrained recursion. The vulnerability allows remote attackers or local users with input access to supply crafted geometry data that exploits the lack of depth limits in the recursive calls. When such malformed inputs are passed through PreparedGeometry::contains or the C API function GEOSPreparedContains against a prepared rectangle, the application enters an infinite loop within the call stack. This behavior is not merely a logical error but a direct path to resource exhaustion, as each recursive invocation consumes additional memory on the system stack until the limit is reached.
The operational impact of this vulnerability is primarily denial of service through process termination. As the recursion continues indefinitely, the application eventually encounters a stack overflow condition, leading to an abrupt crash or segmentation fault. In environments where GEOS is integrated into larger geographic information systems, web mapping services, or spatial databases, such crashes can disrupt critical operations and lead to significant downtime. Furthermore, if the affected service handles requests from untrusted sources without proper input validation or resource limits, this vulnerability could be leveraged for a remote denial of service attack, effectively rendering the system unavailable to legitimate users.
Mitigation strategies should focus on immediate software updates and defensive coding practices. The most effective remediation is upgrading GEOS to version 3.15.1 or later, where the developers have addressed the recursion logic in RectangleContains::isContainedInBoundary to prevent infinite loops with curved geometries. For systems that cannot be immediately updated, implementing input validation at the application layer can help filter out suspiciously complex or malformed geometric structures before they reach the GEOS engine. Additionally, configuring operating system-level stack size limits and utilizing memory protection mechanisms such as Address Space Layout Randomization (ASLR) may mitigate the severity of potential exploitation by limiting the impact of stack overflow events.
In terms of threat modeling, this vulnerability aligns with ATT&CK technique T1499, Endpoint Denial of Service, specifically under sub-techniques involving resource exhaustion via application layer attacks. Security teams should monitor for unusual spikes in memory usage or frequent process restarts associated with spatial data processing services as indicators of potential exploitation attempts. Regular auditing of third-party library dependencies and maintaining an up-to-date inventory of software components is essential to ensure that such known vulnerabilities are promptly patched, thereby reducing the attack surface against sophisticated adversaries seeking to disrupt service availability through geometric computation flaws.