npm
CVE-2026-69152
brace-expansion: DoS via unbounded intermediate arrays, bypassing the CVE-2026-14257 mitigation
- Severity
- High 7.5
- Published
- 3 Aug 2026
- Last changed
- 10 Sept 2026
- Added to UpHeron
- 22 Oct 2026
- Fixed in
- 1.1.18, 2.1.4, 3.0.6, 5.0.9
- Exploit chance
- 0.6% in the next 30 daysHigher than 51% of CVEs. EPSS by FIRST, 19 Nov 2026
- Attack
- Over the network · No login needed · No user action needed
- Attacker can
- Take it down
- CVSS vector
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H- Also known as
- GHSA-rgw5-rvv9-x895
- Sources
- OSV.dev and GitHub
Description
The maxLength mitigation added in 5.0.8 for GHSA-mh99-v99m-4gvg / CVE-2026-14257 is incomplete. It bounds the accumulator where results are combined, but not the intermediate arrays that feed it. A ~25 KB input still crashes the Node process with an uncatchable out-of-memory error, so try/catch around expand() does not help.
A second, related path in the same function lets a ~400 KB input block the event loop for over two minutes without ever exceeding the memory bound.
maxLength was enforced in combine(), the single place output grows. Two arrays are built before combine() runs, and neither was bounded.
1. Comma alternatives accumulate without a running total (memory exhaustion)
Each alternative in {a,b,c,...} is expanded by its own recursive expand_() call, so each receives a full, independent maxLength allowance. The results were then concatenated into a single values array with no cumulative limit:
Workarounds
If upgrading is not immediately possible, avoid passing untrusted input to expand() or to glob brace patterns, or pass an explicitly small max and maxLength.
Note that a small maxLength alone was not sufficient on affected versions: it was applied per alternative rather than cumulatively, which is the root of the first issue above.
Affected software
| Software | Affected versions |
|---|---|
brace-expansionnpm · osv:npm:brace-expansion |
|
About brace-expansion
- Weekly downloads (npm)
- 838,345,228npm, 16 Nov 2026
Vulnerabilities in brace-expansion
- In our list
- 7
- Published in the last 12 months
- 7
- Critical, last 12 months
- 0
- High, last 12 months
- 5
- Known exploited
- 0
- CVE-2026-102277brace-expansion: Quadratic-time expansion of the `{a},b}` rewrite causes CPU denial of serviceMedium 5.3 29 Sept 2026
- CVE-2026-102278brace-expansion: DoS via uncontrolled recursion on nested brace groups causing stack exhaustionHigh 7.5 29 Sept 2026
- CVE-2026-102276brace-expansion: DoS via uncontrolled recursion in parseCommaParts causing stack exhaustionHigh 7.5 29 Sept 2026
- CVE-2026-14257brace-expansion: DoS via unbounded expansion length causing an out-of-memory process crashHigh 7.5 24 Jul 2026
- CVE-2026-13149brace-expansion: DoS via exponential-time expansion of consecutive non-expanding {} groupsHigh 5.3 20 Jul 2026
- CVE-2026-45149brace-expansion: Large numeric range defeats documented `max` DoS protectionMedium 6.5 18 May 2026
References
- CVE.org https://www.cve.org/CVERecord?id=CVE-2026-69152
- GitHub Advisory Database https://github.com/advisories/GHSA-rgw5-rvv9-x895