10.0critical
org.xwiki.platform:xwiki-platform-office-importer vulnerable to arbitrary server side file writing from account through office converter
- Severity
- 10.0critical CVSS:3.1 by GitHub_M
- Exploit likelihood
- 1.36% (higher than 72% of CVEs; EPSS, by FIRST)
- Published
- Last changed
- Assigned by
- GitHub_M
- Also known as
- GHSA-vcvr-v426-3m3m
Description
XWiki Platform is a generic wiki platform offering runtime services for applications built on top of it. Starting in version 3.5-milestone-1 and prior to versions 14.10.8 and 15.3-rc-1, triggering the office converter with a specially crafted file name allows writing the attachment's content to an attacker-controlled location on the server as long as the Java process has write access to that location. In particular in the combination with attachment moving, a feature introduced in XWiki 14.0, this is easy to reproduce but it also possible to reproduce in versions as old as XWiki 3.5 by uploading the attachment through the REST API which doesn't remove `/` or `\` from the filename. As the mime type of the attachment doesn't matter for the exploitation, this could e.g., be used to replace the `jar`-file of an extension which would allow executing arbitrary Java code and thus impact the confidentiality, integrity and availability of the XWiki installation. This vulnerability has been patched in XWiki 14.10.8 and 15.3RC1. There are no known workarounds apart from disabling the office converter.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| xwiki xwiki-platform | >= 3.5-milestone-1, < 14.10.8, >= 15.0-rc-1, < 15.3-rc-1 | CVE List |
| org.xwiki.platform:xwiki-platform-office-importer (Maven) | from 3.5-milestone-1 before 14.10.8, from 15.0-rc-1 before 15.3-rc-1 | GitHub Advisory Database |
| xwiki xwiki | from 3.5 before 14.10.8, from 15.0 before 15.3 | NVD |
All scores
| GitHub_M | 10.0critical CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
| GitHub | 9.9critical CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:C/C:H/I:H/A:H |
| NVD | 8.8high CVSS:3.1 | CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H |
Classification
What each source says
CVE List
XWiki Platform is a generic wiki platform offering runtime services for applications built on top of it. Starting in version 3.5-milestone-1 and prior to versions 14.10.8 and 15.3-rc-1, triggering the office converter with a specially crafted file name allows writing the attachment's content to an attacker-controlled location on the server as long as the Java process has write access to that location. In particular in the combination with attachment moving, a feature introduced in XWiki 14.0, this is easy to reproduce but it also possible to reproduce in versions as old as XWiki 3.5 by uploading the attachment through the REST API which doesn't remove `/` or `\` from the filename. As the mime type of the attachment doesn't matter for the exploitation, this could e.g., be used to replace the `jar`-file of an extension which would allow executing arbitrary Java code and thus impact the confidentiality, integrity and availability of the XWiki installation. This vulnerability has been patched in XWiki 14.10.8 and 15.3RC1. There are no known workarounds apart from disabling the office converter.
GitHub Advisory Database
Impact
Triggering the office converter with a specially crafted file name allows writing the attachment's content to an attacker-controlled location on the server as long as the Java process has write access to that location. In particular in the combination with attachment moving, a feature introduced in XWiki 14.0, this is easy to reproduce but it also possible to reproduce in versions as old as XWiki 3.5 by uploading the attachment through the REST API which doesn't remove / or \ from the filename. As the mime type of the attachment doesn't matter for the exploitation, this could e.g., be used to replace the jar-file of an extension which would allow executing arbitrary Java code and thus impact the confidentiality, integrity and availability of the XWiki installation. To reproduce the issue on versions since XWiki 14.0, execute the following steps:
- Activate the office server
- Upload an arbitrary file with the extension .doc, e.g., to your user profile (you can use a regular plain text file, only the extension matters).
- Use the attachment move feature to rename the file to ../../../../../tmp/Hello from XWiki.txt where the latter part is the location of a file you want to write on the server. The number of ../ depends on the directory depth, the provided example should work on Linux with the demo distribution.
- Click the "preview" link to trigger the office converter
For information how to reproduce on older versions, see the Jira issue.
To the best of our knowledge, this attack is not possible when the office conversion process doesn't run as the code fails before the file is written.
Patches
This vulnerability has been patched in XWiki 14.10.8 and 15.3RC1.
Workarounds
There are no known workarounds apart from disabling the office converter.
References
NVD (es)
XWiki Platform es una plataforma wiki genérica que ofrece servicios de ejecución para aplicaciones creadas sobre ella. A partir de la versión 3.5-milestone-1 y antes de las versiones 14.10.8 y 15.3-rc-1, activar el convertidor de Office con un nombre de archivo especialmente manipulado permite escribir el contenido del archivo adjunto en una ubicación controlada por el atacante en el servidor siempre que el proceso Java tiene acceso de escritura a esa ubicación. En particular, en la combinación con el movimiento de archivos adjuntos, una característica introducida en XWiki 14.0, esto es fácil de reproducir pero también es posible reproducir en versiones tan antiguas como XWiki 3.5 cargando el archivo adjunto a través de la API REST que no elimina `/` o `\` del nombre del archivo. Como el tipo mime del archivo adjunto no importa para la explotación, esto podría usarse, por ejemplo, para reemplazar el archivo `jar` por una extensión que permitiría ejecutar código Java arbitrario y, por lo tanto, afectaría la confidencialidad, integridad y disponibilidad de la instalación de XWiki. Esta vulnerabilidad ha sido parcheada en XWiki 14.10.8 y 15.3RC1. No se conocen workarounds aparte de desactivar el convertidor de Office.
References
| https://github.com/xwiki/xwiki-platform/security/advisories/GHSA-vcvr-v426-3m3m | patch, vendor-advisory, web | |
| https://github.com/xwiki/xwiki-platform/commit/45d182a4141ff22f3ff289cf71e4669bdc714544 | patch, web | |
| https://jira.xwiki.org/browse/XWIKI-20715 | exploit, issue-tracking, patch, vendor-advisory, web | |
| https://nvd.nist.gov/vuln/detail/CVE-2023-37913 | advisory | |
| https://github.com/xwiki/xwiki-platform | package | |
Sources
| Source | Record | Licence |
|---|---|---|
| CVE List | CVE-2023-37913 changed 2024-09-12 | CVE Terms of Use |
| GitHub Advisory Database | GHSA-vcvr-v426-3m3m changed 2026-09-10 | CC-BY-4.0 |
| NVD | CVE-2023-37913 changed 2026-06-17 | Public domain |