XWiki Platform Attachment UI provides a macro to easily upload and select attachments for XWiki Platform, a generic wiki platform. Starting with version 14.0-rc-1 and prior to 14.4-rc-1, it's possible to store JavaScript in an attachment name, which will be executed by anyone trying to move the corresponding attachment. This issue has been patched in XWiki 14.4-rc-1. As a workaround, one may copy moveStep1.vm to webapp/xwiki/templates/moveStep1.vm and replace vulnerable code with code from the patch.
{
"cwe_ids": [
"CWE-79",
"CWE-80"
]
}[
{
"source": "https://github.com/xwiki/xwiki-platform/commit/fbc4bfbae4f6ce8109addb281de86a03acdb9277",
"target": {
"file": "xwiki-platform-core/xwiki-platform-attachment/xwiki-platform-attachment-api/src/test/java/org/xwiki/attachment/MovePageTest.java"
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2022-36097-3730de9a",
"digest": {
"threshold": 0.9,
"line_hashes": [
"144112269652804985430326397908665468734",
"57485369595556582975586920152560715028",
"207927246977508328762372584778434905053",
"194573596879976515878614722227395761160",
"16499835398282794122322877264973357443",
"277387515681275039967405855077853682550",
"327156953449333079698111437528522796853",
"5752128128646401303826784200461671809",
"16763928384127996570742753923879648897",
"14633324937345571916216106436705093076",
"203286788004953815192606822542921980874",
"18843157567650475615792466350873776264",
"95203528425509402192216068284756057307",
"160115172735591751467638760755811950835",
"247133374109632728277349637892570889988",
"165495629888299589995390965710926053194",
"84608063636326994542030844398961951526",
"109471534300483652042738688595425032876",
"330842512226822451419400393701604569921"
]
},
"signature_type": "Line"
},
{
"source": "https://github.com/xwiki/xwiki-platform/commit/fbc4bfbae4f6ce8109addb281de86a03acdb9277",
"target": {
"function": "submitMoveTargetAlreadyExists",
"file": "xwiki-platform-core/xwiki-platform-attachment/xwiki-platform-attachment-api/src/test/java/org/xwiki/attachment/MovePageTest.java"
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2022-36097-7aed8cf3",
"digest": {
"length": 1572.0,
"function_hash": "303656126860523265491399147678069883394"
},
"signature_type": "Function"
},
{
"source": "https://github.com/xwiki/xwiki-platform/commit/fbc4bfbae4f6ce8109addb281de86a03acdb9277",
"target": {
"function": "submitMoveTargetEditNotAllowed",
"file": "xwiki-platform-core/xwiki-platform-attachment/xwiki-platform-attachment-api/src/test/java/org/xwiki/attachment/MovePageTest.java"
},
"deprecated": false,
"signature_version": "v1",
"id": "CVE-2022-36097-ec409297",
"digest": {
"length": 1344.0,
"function_hash": "261912327777436896290540527530319039452"
},
"signature_type": "Function"
}
]