CVE-2023-24807 is a high-severity (CVSS 7.5) Improper Input Validation vulnerability in undici. A fix is available for undici — see the affected versions and patch details below.
Undici vulnerable to Regular Expression Denial of Service in Headers
Exploitation Status
No confirmed exploitation observed yet
- CISA assesses this as automatable — exploitation doesn’t require manual, per-target effort, which raises the odds of mass scanning and opportunistic attacks.
- CISA’s own triage has not observed active exploitation or public proof-of-concept code for this CVE as of its last assessment.
Exploitation and automatability from CISA’s SSVC triage for CVE-2023-24807.
EPSS Exploitation Probability
Probability of exploitation in the next 30 days, from FIRST.org EPSS.
How urgent is this, really
Where this sits among everything scored
Real-World Exposure
How broadly this vulnerability is actually deployed: weekly install volume shows current usage, and reverse-dependency count shows how many other packages break if it stays unpatched.
undicinpmDescription
Impact
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.
Patches
This vulnerability was patched in v5.19.1.
Workarounds
There is no workaround. Please update to an unaffected version.
References
Credits
Carter Snook reported this vulnerability.
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 📦npm | undici | all versions | 5.19.1npm install undici@5.19.1 |
Affected Products
undicinodejsDetection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for undici, including transitive dependencies — a direct dependency you never call can still pull in a vulnerable version.
Fix
Update undici to 5.19.1 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms CVE-2023-24807 is resolved across your whole dependency graph.
Workarounds
Cap what an attacker can consume: apply request size, rate and timeout limits in front of the affected component, and run it with memory and CPU limits so exhaustion degrades one worker rather than the whole service.
Fixing This On Your OS
If you run this on a Linux distribution, patch through your package manager against the distro's own security advisory below — it tracks the exact backported fix for your release, which can ship on a different timeline (and sometimes a different severity) than the upstream project.
| Product | Fixed in | Advisory |
|---|---|---|
| Red Hat Enterprise Linux 8 | nodejs:16-8070020230314140722.bd1311ed | RHSA-2023:1582 |
| Red Hat Enterprise Linux 8 | nodejs:18-8070020230322080930.bd1311ed | RHSA-2023:1583 |
| Red Hat Enterprise Linux 9 | nodejs:18-9020020230327152102.rhel9 | RHSA-2023:2654 |
| Red Hat Enterprise Linux 9 | nodejs-1:16.19.1-1.el9_2 | RHSA-2023:2655 |
| Red Hat Enterprise Linux 9.0 Extended Update Support | nodejs-1:16.20.2-1.el9_0 | RHSA-2023:5533 |
Frequently Asked Questions
Is CVE-2023-24807 in your dependencies?
Find it across npm, including transitive dependencies.