CONTENTUM.COMA specialist. A plan. A result.

Vulnerabilities · 2020

CVE-2020-7773
Markdown-it-highlightjs Project Markdown-it-highlightjs vulnerability

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

Affected products

Markdown-it-highlightjs. The exact versions are in the references.

What to do now

  • Check your exposureFind out whether Markdown-it-highlightjs Project Markdown-it-highlightjs runs anywhere in your environment, including systems of suppliers.
  • UpdateInstall the version in which the vendor fixed the vulnerability. The references lead to the advisory.
  • Limit access until thenIf you cannot update at once, take the system off the internet or restrict who can reach it.

References

Data: CVE list and the NVD. This product uses data from the NVD API but is not endorsed or certified by the NVD.