CVE-2012-5881: Yui2 Cross-Site Scripting Vulnerability
MODERATECVE-2012-5881 is a MODERATE cross-site scripting vulnerability (CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting')) affecting Yui2 libraries in the npm ecosystem. The issue involves cross-site scripting in yui 2.4.0. Remediation is available in the latest vendor maintenance releases.
CVE-2012-5881 at a Glance
How to Fix CVE-2012-5881
To remediate this vulnerability, upgrade all affected Yui2 dependencies to a patched release. Both direct and transitive dependencies should be checked, as frameworks or security libraries may pull in vulnerable versions transitively.
npm install yui2@Latest secure release
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls yui2
How to Check if You Are Affected
To determine whether your Node.js application is affected by CVE-2012-5881, inspect your project dependencies using npm:
npm ls yui2
Analyze the terminal output to locate any version of Yui2 in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than the patched release), your application is affected.
Note: The npm ls yui2 command inspects dependencies declared in your package.json and lockfile; it does not perform automated runtime dynamic scanning.
Technical Details
Vulnerability Mechanism & Technical Analysis
This vulnerability is classified under CWE-79: Improper Neutralization of Input During Web Page Generation ('Cross-site Scripting'), where 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. In Yui2, 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-2012-5881 Affected Yui2 Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
yui2
|
npm |
≥ 2.4.0
≤ 2.9.0
|
|
References
Frequently Asked Questions
What is CVE-2012-5881?
Which Yui2 versions are affected?
What version fixes CVE-2012-5881?
Is yui2 affected?
What CWE is associated with CVE-2012-5881?
How can I check npm dependencies for CVE-2012-5881?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-jjg9-mf63-vqrp",
"modified" : "2024-01-09T21:54:51Z",
"published" : "2022-05-17T01:38:30Z",
"aliases" : [ "CVE-2012-5881" ],
"summary" : "Cross-site scripting in yui 2.4.0",
"details" : "Cross-site scripting (XSS) vulnerability in the Flash component infrastructure in YUI 2.4.0 through 2.9.0 allows remote attackers to inject arbitrary web script or HTML via vectors related to charts.swf, a similar issue to CVE-2010-4207.",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "yui2"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "2.4.0"
}, {
"last_affected" : "2.9.0"
} ]
} ]
} ],
"references" : [ {
"type" : "ADVISORY",
"url" : "https://nvd.nist.gov/vuln/detail/CVE-2012-5881"
}, {
"type" : "WEB",
"url" : "https://exchange.xforce.ibmcloud.com/vulnerabilities/80118"
}, {
"type" : "WEB",
"url" : "http://www.securityfocus.com/bid/56385"
}, {
"type" : "WEB",
"url" : "http://www.yuiblog.com/blog/2012/10/30/security-announcement-swf-vulnerability-in-yui-2"
}, {
"type" : "WEB",
"url" : "http://www.yuiblog.com/blog/2012/11/05/post-mortem-swf-vulnerability-in-yui-2"
}, {
"type" : "WEB",
"url" : "http://yuilibrary.com/support/20121030-vulnerability"
} ],
"database_specific" : {
"cwe_ids" : [ "CWE-79" ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2024-01-09T21:54:51Z",
"nvd_published_at" : "2012-11-16T12:24:00Z"
}
}