CVE-2026-14257: CWE-400 Uncontrolled Resource Consumption in juliangruber brace-expansion
CVE-2026-14257 is a high-severity vulnerability in the juliangruber brace-expansion library (versions up to 5.0.7) that allows an attacker to cause uncontrolled memory consumption. The expand() function limits the number of results but not their length, enabling crafted inputs with many chained brace groups to exhaust memory and crash the Node.js process with an uncatchable out-of-memory error. This denial-of-service condition cannot be caught by try/catch and results in a fatal process termination. The vulnerability affects applications that pass attacker-controlled strings to brace-expansion.expand(), including via minimatch or glob patterns. A patch has been released that bounds the total output length to prevent unbounded memory growth.
AI Analysis
Technical Summary
The vulnerability arises because the expand() function in juliangruber brace-expansion caps the number of expansions but not the length of each expansion. By chaining many brace groups (e.g., '{a,b}'.repeat(N)), the number of results is capped at 100,000 by default, but each result grows linearly with N in length. This causes memory usage to scale with max × N, leading to excessive memory consumption and a fatal out-of-memory crash in the Node.js process. The crash is uncatchable because it is a V8 fatal error, not a thrown exception. The fix introduces a maxLength limit (default 4,000,000 characters) on the total output length, truncating expansions to prevent unbounded memory use. This fix is available in patched releases beyond version 5.0.7.
Potential Impact
Applications using vulnerable versions of brace-expansion (<=5.0.7) that process attacker-controlled input can be crashed by a crafted input string that triggers excessive memory allocation. The crash is a fatal V8 out-of-memory error that cannot be caught or handled, resulting in denial of service by terminating the Node.js process or worker. This impacts availability but does not directly compromise confidentiality or integrity.
Mitigation Recommendations
Upgrade to a patched release of juliangruber brace-expansion beyond version 5.0.7 that includes the maxLength output length bounding fix. This fix prevents unbounded memory growth and fatal crashes. If upgrading immediately is not possible, avoid passing untrusted or attacker-controlled input to expand() or glob brace patterns, or explicitly configure both max and maxLength options to small values to limit resource consumption. The vendor advisory confirms the fix is available and effective.
CVE-2026-14257: CWE-400 Uncontrolled Resource Consumption in juliangruber brace-expansion
Description
CVE-2026-14257 is a high-severity vulnerability in the juliangruber brace-expansion library (versions up to 5.0.7) that allows an attacker to cause uncontrolled memory consumption. The expand() function limits the number of results but not their length, enabling crafted inputs with many chained brace groups to exhaust memory and crash the Node.js process with an uncatchable out-of-memory error. This denial-of-service condition cannot be caught by try/catch and results in a fatal process termination. The vulnerability affects applications that pass attacker-controlled strings to brace-expansion.expand(), including via minimatch or glob patterns. A patch has been released that bounds the total output length to prevent unbounded memory growth.
CVSS v3.1
Score 7.5high
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The vulnerability arises because the expand() function in juliangruber brace-expansion caps the number of expansions but not the length of each expansion. By chaining many brace groups (e.g., '{a,b}'.repeat(N)), the number of results is capped at 100,000 by default, but each result grows linearly with N in length. This causes memory usage to scale with max × N, leading to excessive memory consumption and a fatal out-of-memory crash in the Node.js process. The crash is uncatchable because it is a V8 fatal error, not a thrown exception. The fix introduces a maxLength limit (default 4,000,000 characters) on the total output length, truncating expansions to prevent unbounded memory use. This fix is available in patched releases beyond version 5.0.7.
Potential Impact
Applications using vulnerable versions of brace-expansion (<=5.0.7) that process attacker-controlled input can be crashed by a crafted input string that triggers excessive memory allocation. The crash is a fatal V8 out-of-memory error that cannot be caught or handled, resulting in denial of service by terminating the Node.js process or worker. This impacts availability but does not directly compromise confidentiality or integrity.
Mitigation Recommendations
Upgrade to a patched release of juliangruber brace-expansion beyond version 5.0.7 that includes the maxLength output length bounding fix. This fix prevents unbounded memory growth and fatal crashes. If upgrading immediately is not possible, avoid passing untrusted or attacker-controlled input to expand() or glob brace patterns, or explicitly configure both max and maxLength options to small values to limit resource consumption. The vendor advisory confirms the fix is available and effective.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- seal
- Date Reserved
- 2026-06-30T15:45:06.757Z
- Cvss Version
- 3.1
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a6215a29c2644c7f82072c2
Added to database: 07/23/2026, 13:22:42 UTC
Last enriched: 08/01/2026, 21:31:25 UTC
Last updated: 09/07/2026, 10:52:06 UTC
Views: 247
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.