Skip to content
RCE Write-up Advanced

Critical GeoServer RCE Vulnerability (CVE-2024–36401) — N

GeoServer passes attribute names to the commons-jxpath library, which evaluates them as XPath expressions without proper sanitisation, and a misconfiguration applies this to all feature types. An unauthenticated attacker can send crafted requests to default endpoints and execute arbitrary code, gaining full control of the server.

AerieWhole123 Follow

Published on medium.com

A severe remote code execution (RCE) vulnerability has been discovered in GeoServer, an open-source platform for managing and sharing geospatial data. Identified as CVE-2024–36401, this flaw allows unauthenticated attackers to execute arbitrary code on affected servers — no login required.

AerieWhole123, on medium.com

The full write-up lives on its author's site

It belongs to its author, so we link to it rather than copy it. The other two tabs are our own rewrites, checked against it.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

How it worked

Root cause

Attribute names are passed to commons-jxpath and evaluated as XPath without sanitisation, and a misconfiguration extends this behaviour from complex feature types to all features.

Impact

Unauthenticated attackers could achieve full remote code execution, leading to system takeover, data theft or manipulation, ransomware injection, and lateral movement inside internal networks.

What the attacker needed

GeoServer running an affected version; No authentication needed; Network access to GeoServer endpoints

The fix

Upgrade to a patched version and replace the vulnerable JARs (gt-app-schema, gt-complex, gt-xsd-core); removing gt-complex is a temporary mitigation but may break functionality.

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this write-up has not been written yet. The Original tab links to the source.

GeoServer is a server for sharing map data. It takes some user-supplied names and treats them as instructions in a mini-language called XPath, without checking them first. Because of a setup mistake, this happens for every kind of data, so an attacker who sends a specially crafted request can make the server run their code.

What is RCE?

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.

More by AerieWhole123

View all

16 more disclosed reports, best first.

Similar reports

View all

Same bug class and techniques, clearest first.

Remote code execution

The lesson behind this report.

Running the attacker's code on the target's servers: through command or code injection, unsafe deserialisation or template injection.