What’s Vulnerable › Vulnerabilities
CVE-2023-24807: Undici vulnerable to Regular Expression Denial of Service in Headers
- Severity: high (CVSS 7.5 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 1.3% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2023-02-16 · updated 2026-06-17
- Weakness: CWE-20
Description
Undici is an HTTP/1.1 client for Node.js. Prior to version 5.19.1, the `Headers.set()` and `Headers.append()` methods are vulnerable to Regular Expression Denial of Service (ReDoS) attacks when untrusted values are passed into the functions. This is due to the inefficient regular expression used to normalize the values in the `headerValueNormalize()` utility function. This vulnerability was patched in v5.19.1. No known workarounds are available.
Affected products
- undici: before 5.19.1 — fixed in 5.19.1
- Npm Undici: before 5.19.1 — fixed in 5.19.1
How to fix
Upgrade to a fixed version: undici 5.19.1; Npm Undici 5.19.1. Check the vendor advisory for mitigations.
References
- https://github.com/nodejs/undici/commit/f2324e549943f0b0937b09fb1c0c16cc7c93abdf
- https://github.com/nodejs/undici/releases/tag/v5.19.1
- https://github.com/nodejs/undici/security/advisories/GHSA-r6ch-mqf9-qc9w
- https://hackerone.com/bugs?report_id=1784449
- https://github.com/nodejs/undici/commit/f2324e549943f0b0937b09fb1c0c16cc7c93abdf
- https://github.com/nodejs/undici/releases/tag/v5.19.1
- https://github.com/nodejs/undici/security/advisories/GHSA-r6ch-mqf9-qc9w
- https://hackerone.com/bugs?report_id=1784449
- https://security.netapp.com/advisory/ntap-20230324-0010/
Get alerted when CVE-2023-24807 or the next vulnerability affects your stack