XSS in Markdown-It-Highlightjs Project

CVE-2020-7773

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);

Vulnerability class: XSS (Cross-Site Scripting)

EPSS: 0.013 (68.5th percentile) — read the EPSS interpretation.

CVSS v3 metric

CVSS v3 base score 6.5 (Medium). Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:N/A:N.

Affected products

Weakness classification (CWE)

References

Frequently asked questions

What is CVE-2020-7773?
CVE-2020-7773 is a medium-severity vulnerability in Markdown-It-Highlightjs Project, classified under Cross-site Scripting. CVSS score: 6.5/10. Published 2020-11-16.
How severe is CVE-2020-7773?
Medium severity. CVSS v3 base score is 6.5 out of 10.