Vulnerability Description
This affects the package markdown-it-highlightjs before 3.3.1. It is possible insert malicious JavaScript as a value of lang in the markdown-it-highlightjs Inline code highlighting feature. const markdownItHighlightjs = require("markdown-it-highlightjs"); const md = require('markdown-it'); const reuslt_xss = md() .use(markdownItHighlightjs, { inline: true }) .render('console.log(42){.">js}'); console.log(reuslt_xss);
CVSS Score
MEDIUM
Affected Products
| Vendor | Product | Versions |
|---|---|---|
| Markdown-It-Highlightjs Project | Markdown-It-Highlightjs | < 3.3.1 |
Related Weaknesses (CWE)
References
- https://github.com/valeriangalliat/markdown-it-highlightjs/blob/v3.3.0/index.js%Broken Link
- https://github.com/valeriangalliat/markdown-it-highlightjs/pull/14ExploitThird Party Advisory
- https://snyk.io/vuln/SNYK-JS-MARKDOWNITHIGHLIGHTJS-1040461MitigationThird Party Advisory
- https://github.com/valeriangalliat/markdown-it-highlightjs/blob/v3.3.0/index.js%Broken Link
- https://github.com/valeriangalliat/markdown-it-highlightjs/pull/14ExploitThird Party Advisory
- https://snyk.io/vuln/SNYK-JS-MARKDOWNITHIGHLIGHTJS-1040461MitigationThird Party Advisory
FAQ
What is CVE-2020-7773?
CVE-2020-7773 is a vulnerability with a CVSS score of 6.5 (MEDIUM). This affects the package markdown-it-highlightjs before 3.3.1. It is possible insert malicious JavaScript as a value of lang in the markdown-it-highlightjs Inline code highlighting feature. const mark...
How severe is CVE-2020-7773?
CVE-2020-7773 has been rated MEDIUM with a CVSS base score of 6.5/10. Review the CVSS metrics above for detailed severity breakdown.
Is there a patch for CVE-2020-7773?
Check the references section above for vendor advisories and patch information. Affected products include: Markdown-It-Highlightjs Project Markdown-It-Highlightjs.