GHSA-8wp3-cp9v-44fm: Marked Cross-Site Scripting Vulnerability
MODERATEGHSA-8wp3-cp9v-44fm is a MODERATE cross-site scripting vulnerability (General Security Weakness) affecting Marked libraries in the npm ecosystem. The issue involves cross-site scripting in marked. Remediation is available by upgrading affected packages to version 0.3.9.
GHSA-8wp3-cp9v-44fm at a Glance
How to Fix GHSA-8wp3-cp9v-44fm
To remediate this vulnerability, upgrade all affected Marked 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 marked@0.3.9
Run the following command in your project directory to verify that all resolved dependencies use the patched release:
npm ls marked
How to Check if You Are Affected
To determine whether your Node.js application is affected by GHSA-8wp3-cp9v-44fm, inspect your project dependencies using npm:
npm ls marked
Analyze the terminal output to locate any version of Marked in your dependency tree. If any resolved version matches the vulnerable ranges listed in the table below (for example, versions earlier than 0.3.9), your application is affected.
Note: The npm ls marked 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 General Security Weakness. In Marked, 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
GHSA-8wp3-cp9v-44fm Affected Marked Versions
1 component(s)| Product / Package | Ecosystem | Affected Versions | Fixed Version |
|---|---|---|---|
|
marked
|
npm |
< 0.3.9
|
0.3.9
|
References
Frequently Asked Questions
What is GHSA-8wp3-cp9v-44fm?
Which Marked versions are affected?
What version fixes GHSA-8wp3-cp9v-44fm?
Is marked affected?
What CWE is associated with GHSA-8wp3-cp9v-44fm?
How can I check npm dependencies for GHSA-8wp3-cp9v-44fm?
Machine-readable OSV JSON
OSV v1.5 Schema
{
"schema_version" : "1.4.0",
"id" : "GHSA-8wp3-cp9v-44fm",
"modified" : "2021-02-25T02:01:15Z",
"published" : "2021-02-25T02:01:15Z",
"withdrawn" : "2021-02-25T02:01:15Z",
"aliases" : [ ],
"summary" : "Cross-Site Scripting in marked",
"details" : "Versions 0.3.7 and earlier of marked unescape only lowercase while owsers support both lowercase and uppercase x in hexadecimal form of HTML character entity",
"severity" : [ ],
"affected" : [ {
"package" : {
"ecosystem" : "npm",
"name" : "marked"
},
"ranges" : [ {
"type" : "ECOSYSTEM",
"events" : [ {
"introduced" : "0"
}, {
"fixed" : "0.3.9"
} ]
} ]
} ],
"references" : [ {
"type" : "WEB",
"url" : "https://github.com/markedjs/marked/issues/925"
}, {
"type" : "WEB",
"url" : "https://github.com/markedjs/marked/commit/6d1901ff71abb83aa32ca9a5ce47471382ea42a9"
} ],
"database_specific" : {
"cwe_ids" : [ ],
"severity" : "MODERATE",
"github_reviewed" : true,
"github_reviewed_at" : "2019-06-05T12:47:45Z",
"nvd_published_at" : null
}
}