Vulnerabilities in pkg:maven/com.xpn.xwiki.platform/xwiki-core-rest-server
PACKAGECVE-2023-37277 is a CRITICAL (CVSS 9.6) xwiki platform vulnerable to cross-site vulnerability (CWE-352: Cross-Site Request Forgery (CSRF)) affecting Xwiki platform rest server libraries in the Maven ecosystem. The issue involves xwiki platform vulnerable to cross-site request forgery (csrf) via the rest api. Remediation is available by upgrading affected packages to version 14.10.8, 15.2.
pkg:maven/com.xpn.xwiki.platform/xwiki-core-rest-server
Vulnerability advisories affecting package pkg:maven/com.xpn.xwiki.platform/xwiki-core-rest-server. Select an advisory below to view technical details or fixes.
| Advisory ID | CVE / NVD | Severity | Summary |
|---|---|---|---|
| GHSA-6xxr-648m-gch6 | CVE-2023-37277 | CRITICAL | XWiki Platform vulnerable to cross-site request forgery (CSRF) via the REST API |
CVE-2023-37277 at a Glance
Security Impact
CVSS: 9.6
The security impact metrics below are parsed directly from the CVSS v3.1 vector string (CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H).
How to Fix CVE-2023-37277
To remediate this vulnerability, upgrade all affected Xwiki platform rest server 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.xwiki.platform</groupId>
<artifactId>xwiki-platform-rest-server</artifactId>
<version>14.10.8</version>
</dependency>
<dependency>
<groupId>com.xpn.xwiki.platform</groupId>
<artifactId>xwiki-core-rest-server</artifactId>
<version>14.10.8</version>
</dependency>
<dependency>
<groupId>com.xpn.xwiki.platform</groupId>
<artifactId>xwiki-rest</artifactId>
<version>14.10.8</version>
</dependency>
<dependency>
<groupId>org.xwiki.platform</groupId>
<artifactId>xwiki-platform-rest-server</artifactId>
<version>15.2</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.xwiki.platform
How to Check if You Are Affected
To determine whether your Java application is affected by CVE-2023-37277, inspect your build dependencies using the Maven Dependency Plugin:
mvn dependency:tree -Dincludes=org.xwiki.platform
Analyze the terminal output to locate any version of Xwiki platform rest server in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 14.10.8), your application is affected.
Note: The mvn dependency:tree -Dincludes=org.xwiki.platform 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-352: Cross-Site Request Forgery (CSRF), where the web application does not, or cannot, sufficiently verify whether a request was intentionally provided by the user who sent the request, which could have originated from an unauthorized actor. In Xwiki platform rest server, 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-37277 Affected Xwiki platform rest server Versions
4 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
org.xwiki.platform:xwiki-platform-rest-server
|
Maven |
≥ 1.8
< 14.10.8
|
14.10.8
|
|
com.xpn.xwiki.platform:xwiki-core-rest-server
|
Maven |
≥ 1.8
< 14.10.8
|
14.10.8
|
|
com.xpn.xwiki.platform:xwiki-rest
|
Maven |
≥ 1.8
< 14.10.8
|
14.10.8
|
|
org.xwiki.platform:xwiki-platform-rest-server
|
Maven |
≥ 15.0-rc-1
< 15.2
|
15.2
|
References
Frequently Asked Questions
What is CVE-2023-37277?
Which Xwiki platform rest server versions are affected?
What version fixes CVE-2023-37277?
Is xwiki-platform-rest-server affected?
Is xwiki-core-rest-server affected?
What is the CVSS score of CVE-2023-37277?
What CWE is associated with CVE-2023-37277?
How can I check Maven dependencies for CVE-2023-37277?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-6xxr-648m-gch6",
"modified" : "2023-07-10T21:53:12Z",
"published" : "2023-07-10T21:53:12Z",
"aliases" : [ "CVE-2023-37277" ],
"summary" : "XWiki Platform vulnerable to cross-site request forgery (CSRF) via the REST API",
"details" : "### Impact\n\nThe REST API allows executing all actions via POST requests and accepts `text/plain`, `multipart/form-data` or `application/www-form-urlencoded` as content types which can be sent via regular HTML forms, thus allowing cross-site request forgery. With the interaction of a user with programming rights, this allows remote code execution through script macros and thus impacts the integrity, availability and confidentiality of the whole XWiki installation.\n\nFor regular cookie-based authentication, the vulnerability is mitigated by SameSite cookie restrictions but as of March 2023, these are not enabled by default in Firefox and Safari.\n\n### Patches\nThe vulnerability has been patched in XWiki 14.10.8 and 15.2 by requiring a CSRF token header for certain request types that are susceptible to CSRF attacks.\n\n### Workarounds\n\nIt is possible to check for the `Origin` header in a reverse proxy to protect the REST endpoint from CSRF attacks, see [the Jira issue](https://jira.xwiki.org/browse/XWIKI-20135) for an example configuration.\n\n### References\n\n* https://jira.xwiki.org/browse/XWIKI-20135\n* https://github.com/xwiki/xwiki-platform/commit/4c175405faa0e62437df397811c7526dfc0fbae7\n",
"severity" : [ {
"type" : "CVSS_V3",
"score" : "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:C/C:H/I:H/A:H"
} ],
"affected" : [ {
"package" : {
"ecosystem" : "Maven",
"name" : "org.xwiki.platform:xwiki-platform-rest-server"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.8"
}, {
"fixed" : "14.10.8"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "com.xpn.xwiki.platform:xwiki-core-rest-server"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.8"
}, {
"fixed" : "14.10.8"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "com.xpn.xwiki.platform:xwiki-rest"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "1.8"
}, {
"fixed" : "14.10.8"
} ]
} ]
}, {
"package" : {
"ecosystem" : "Maven",
"name" : "org.xwiki.platform:xwiki-platform-rest-server"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "15.0-rc-1"
}, {
"fixed" : "15.2"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/xwiki/xwiki-platform/security/advisories/GHSA-6xxr-648m-gch6"
}, {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2023-37277"
}, {
"type" : "WEB",
"url" : "https://github.com/xwiki/xwiki-platform/commit/4c175405faa0e62437df397811c7526dfc0fbae7"
}, {
"type" : "PACKAGE",
"url" : "https://github.com/xwiki/xwiki-platform"
}, {
"type" : "WEB",
"url" : "https://jira.xwiki.org/browse/XWIKI-20135"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-352" ],
"severity" : "CRITICAL",
"github_reviewed" : true,
"github_reviewed_at" : "2023-07-10T21:53:12Z",
"nvd_published_at" : "2023-07-10T17:15:09Z"
}
}