Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Stored XSS through attributes provided to the 3d parser tag/function

High
dolfinus publishedGHSA-f2rp-232x-mqrhSep 15, 2025

Package

3DAlloy (MediaWiki)

Affected versions

>= 1.0

Patched versions

>= 1.9

Description

Summary

The<3d> parser tag and the{{#3d}} parser function allow users to provide custom attributes that are then appended to the canvas HTML element that is being output by the extension. The attributes are not sanitized, which means that arbitrary JavaScript can be inserted and executed.

Details

In the code of the<3d> tag, the$args provided to the tag are stored in theparams array:

$params =array_merge($wg3DAlloy,$args);

Then, the$par array is populated with these values:
$par = [];
foreach ($paramsas$key =>$value) {
if ($value !=='') {
$par[$key] =$value;
}
}

The arguments are then used as attributes for the HTML element that is being output:
$elem = Html::element('canvas',$par,$input);
return [$elem,'noParse'=>true,'isHTML'=>'true' ];


A similar thing is done for the{{#3d}} parser function:

$i=0;
foreach ($wg3DAlloyas$param=>$value) {
if (isset($args[$i])) {
$args[$i] =$param."=".$args[$i];
}else {
$args[$i] =$param."=".$value;
}
$i++;
}
$params = [];
parse_str(implode("&",$args),$params);
$params =array_merge($wg3DAlloy,$params);

$par = [];
foreach ($paramsas$key =>$value) {
if ($value !=='') {
$par[$key] =$value;
}
}

$elem = Html::element('canvas',$par,$params["file"]);

PoC

  1. Create a wiki page with the following contents:
<3donmouseenter=alert(1)>Test</3d>{{#3d:Model.json|width|height|color|opacity|zoom|pan|norotate|scale|z|style|class|onmouseenter=alert(2)}}
  1. Hover over either of the 3D viewers
imageimage

Impact

Arbitrary JS can be executed by any user, which can lead to consequences like privilege escalation, DOS or infoleaks.

Severity

High

CVSS overall score

This score calculates overall vulnerability severity from 0 to 10 and is based on the Common Vulnerability Scoring System (CVSS).
/ 10

CVSS v3 base metrics

Attack vector
Network
Attack complexity
Low
Privileges required
None
User interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
Low
Availability
Low

CVSS v3 base metrics

Attack vector:More severe the more the remote (logically and physically) an attacker can be in order to exploit the vulnerability.
Attack complexity:More severe for the least complex attacks.
Privileges required:More severe if no privileges are required.
User interaction:More severe when no user interaction is required.
Scope:More severe when a scope change occurs, e.g. one vulnerable component impacts resources in components beyond its security scope.
Confidentiality:More severe when loss of data confidentiality is highest, measuring the level of data access available to an unauthorized user.
Integrity:More severe when loss of data integrity is the highest, measuring the consequence of data modification possible by an unauthorized user.
Availability:More severe when the loss of impacted component availability is highest.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:L/A:L

CVE ID

CVE-2025-59332

Weaknesses

Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')

The product does not neutralize or incorrectly neutralizes user-controllable input before it is placed in output that is used as a web page that is served to other users.Learn more on MITRE.

Credits


[8]ページ先頭

©2009-2025 Movatter.jp