What’s Vulnerable › Vulnerabilities
CVE-2021-21306: Denial of Service in Marked
- Severity: high (CVSS 7.5 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 2.5% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2021-02-08 · updated 2026-06-17
- Weakness: CWE-400
Description
Marked is an open-source markdown parser and compiler (npm package "marked"). In marked from version 1.1.1 and before version 2.0.0, there is a Regular expression Denial of Service vulnerability. This vulnerability can affect anyone who runs user generated code through marked. This vulnerability is fixed in version 2.0.0.
Affected products
- markedjs marked: from 1.1.1 before 2.0.0 — fixed in 2.0.0
How to fix
Upgrade to a fixed version: markedjs marked 2.0.0. Check the vendor advisory for mitigations.
References
- https://github.com/markedjs/marked/commit/7293251c438e3ee968970f7609f1a27f9007bccd
- https://github.com/markedjs/marked/issues/1927
- https://github.com/markedjs/marked/pull/1864
- https://github.com/markedjs/marked/security/advisories/GHSA-4r62-v4vq-hr96
- https://www.npmjs.com/package/marked
- https://github.com/markedjs/marked/commit/7293251c438e3ee968970f7609f1a27f9007bccd
- https://github.com/markedjs/marked/issues/1927
- https://github.com/markedjs/marked/pull/1864
- https://github.com/markedjs/marked/security/advisories/GHSA-4r62-v4vq-hr96
- https://www.npmjs.com/package/marked
Get alerted when CVE-2021-21306 or the next vulnerability affects your stack