# CVE-2019-25103: simple-markdown regular expression denial of service

Source: https://junglewise.ai/threats/cve-2019-25103-simple-markdown-regular-expression-denial-of-service  
Publisher: Junglewise Threat Intelligence, https://junglewise.ai/threats  
Published: 2023-02-12. Updated: 2026-09-25  
License: CC BY 4.0 with a link back

CVE-2019-25103 · Severity: low · CVSS 3.1 · Published 2023-02-12

simple-markdown is a JavaScript library used to convert markdown text into HTML. A regular expression parsing flaw allows an attacker to craft malicious input that causes the parser to consume excessive CPU resources, resulting in application slowdown or unavailability. This could impact any web application or service that uses simple-markdown to process untrusted user input.

Technologies: [simple-markdown (npm)](https://junglewise.ai/threats/technologies/simple-markdown). Vendors: [npm](https://junglewise.ai/threats/vendors/npm).

## Quick answers

**Is CVE-2019-25103 exploited in the wild?** No. Junglewise Threat Intelligence has no report of CVE-2019-25103 being exploited in the wild.

**How severe is CVE-2019-25103?** Low severity, with a CVSS score of 3.1, published 12 February 2023.

**Which products and versions are affected?** simple-markdown (npm) SEMVER:introduced=0,fixed=0.5.2.

**Is there a fix for CVE-2019-25103?** Yes. simple-markdown (npm): upgrade to 0.5.2 or later. Junglewise finds every place you run it, drafts the upgrade and applies it once you approve.

**How is CVE-2019-25103 attacked?** It is attacked over the network.

**Am I affected by CVE-2019-25103?** Check whether you run simple-markdown (npm) at an affected version. Junglewise does that check for you around the clock: connect your code, cloud and domains, and it matches new vulnerabilities like this one against what you actually run and tells you when one reaches you.

## How to fix

- simple-markdown (npm): upgrade to 0.5.2 or later

  ```sh
  npm install simple-markdown@0.5.2
  ```


## Technical details

The vulnerability is a Regular Expression Denial of Service (ReDoS) flaw affecting the markdown parsing logic in simple-markdown.js, classified as CWE-1333 (inefficient regular expression complexity). An attacker can provide specially crafted markdown input to the parser that triggers catastrophic backtracking in one or more regular expressions, causing the parser to hang or consume significant CPU cycles. The attack requires no authentication and can be launched remotely against any service that accepts markdown input. The vulnerability affects all versions prior to 0.5.2, which includes a patch (commit 89797fef9abb4cab2fb76a335968266a92588816) that optimizes the affected regular expressions. Upgrading to version 0.5.2 or later resolves the issue.

## Affected products

- Khan Academy simple-markdown before 0.5.2

## Identifiers

- CVE-2019-25103
- GHSA-gpvj-gp8c-c7p2

## Timeline

- 2023-02-12: disclosed
- 0.5.2: patched: Upgrade to version 0.5.2 or later

## References

- [https://github.com/Khan/simple-markdown/issues/71](https://github.com/Khan/simple-markdown/issues/71)

## Related threats

- [simple-markdown regular expression denial of service](https://junglewise.ai/threats/cve-2019-25102-simple-markdown-regular-expression-denial-of-service)
- [simple-markdown regular expression denial of service](https://junglewise.ai/threats/simple-markdown-regular-expression-denial-of-service-a4876976)
- [simple-markdown cross-site scripting in link handling](https://junglewise.ai/threats/cve-2019-9844-simple-markdown-cross-site-scripting-in-link-handling)
