🛡️ CVE-2022-36097 — xwiki

🟠 CVSS 8.9 — High ✅ No Known Exploit CWE-79 NVD
8.9
CVSS Score
0 Low4 Medium7 High9 Critical10

Description

XWiki Platform Attachment UI vulnerable to cross-site scripting in the move attachment form

Impact

It's possible to store JavaScript in an attachment name, which will be executed by anyone trying to move the corresponding attachment.

For example, an attachment with name ><img src=1 onerror=alert(1)>.jpg will execute the alert.

Patches

This issue has been patched in XWiki 14.4RC1.

Workarounds

It is possible to fix the vulnerability by copying [moveStep1.vm](https://raw.githubusercontent.com/xwiki/xwiki-platform/xwiki-platform-14.0-rc-1/xwiki-platform-core/xwiki-platform-attachment/xwiki-platform-attachment-api/src/main/resources/templates/attachment/moveStep1.vm) to webapp/xwiki/templates/moveStep1.vm and replace

```

#set($titleToDisplay = $services.localization.render('attachment.move.title',

[$attachment.name, $escapetool.xml($doc.plainTitle), $doc.getURL()]))

```

by

```

#set($titleToDisplay = $services.localization.render('attachment.move.title', [

$escapetool.xml($attachment.name),

$escapetool.xml($doc.plainTitle),

$escapetool.xml($doc.getURL())

]))

```

See the corresponding [patch](https://github.com/xwiki/xwiki-platform/commit/fbc4bfbae4f6ce8109addb281de86a03acdb9277).

References

  • https://jira.xwiki.org/browse/XWIKI-19667

For more information

If you have any questions or comments about this advisory:

How this vulnerability can be exploited

This issue can be reached over the network, attack complexity is low, an attacker needs low-level privileges on the target. A user must be tricked into taking some action. The scope is changed, meaning a successful attack can affect components beyond the vulnerable one. Rated impact: confidentiality high, integrity high, availability low.

Weakness class

CVE-2022-36097 is classified as CWE-79: Cross-site Scripting (XSS). User-supplied data is written into a page without escaping, so attacker script runs in the browser of anyone who views it.

Affected software

CVE-2022-36097 is recorded against 2 packages.

  • org.xwiki.platform:xwiki-platform-attachment-ui (from 14.0-rc-1 up to 14.4-rc-1)
  • xwiki (from 14.0 up to 14.3)

Timeline and source

Published on 16 September 2022 and last revised on 8 November 2023. No public exploit is currently recorded for this entry. A vendor advisory or fix has been published. Record sourced from NVD.

References

github.com (Web)
nvd.nist.gov (Advisory)
github.com (Web)
github.com (Package)
jira.xwiki.org (Web)
raw.githubusercontent.com (Web)

Details

Severity HIGH
CVSS Score 8.9
CVSS Vector CVSS:3.1/AV:N/AC:L/PR:L/UI:R/S:C/C:H/I:H/A:L
CWE CWE-79
Public Exploit ✅ No
Source NVD
Published 2022-09-16
Updated 2026-08-12
Modified 2023-11-08

Affected Packages

Software From version Fixed in
org.xwiki.platform:xwiki-platform-attachment-ui 14.0-rc-1 14.4-rc-1
xwiki 14.0 14.3

Similar Threats

Site Security Check

Is xwiki part of your stack?

CVE-2022-36097 is rated CVSS 8.9 High. BotEraser scans your installation against known CVE records and tells you whether this vulnerability applies to the versions you actually run.

Scan My Site Free →

No credit card required  ·  Results in minutes

ⓘ Data Notice: The information presented above has been compiled from publicly available internet sources. Boteraser aggregates this data solely for informational purposes and does not independently classify, evaluate, or endorse any findings about the vulnerabilities listed. The accuracy and completeness of this information is the sole responsibility of the original publishers. Boteraser and its operators accept no liability for any decisions made based on this data.