# CVE-2026-14257: brace-expansion DoS via unbounded expansion length causing an out-of-memory process crash

> An attacker can crash a Node.js process by providing crafted input to the brace-expansion library, causing memory exhaustion.

- **Severity:** High 7.5 (`CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H`)
- **Exploited in the wild:** Not known
- **Login needed:** Not needed
- **Attackable:** Over the internet
- **Victim action needed:** Not needed
- **Fix available:** Yes
- **Published:** 23 Jul 2026
- **Updated:** 23 Jul 2026
- **Also known as:** AZL-94520, AZL-94535, CLEANSTART-2026-EH67638, CLEANSTART-2026-IZ75893, CLEANSTART-2026-JX26163, CLEANSTART-2026-NJ03558, CLSA-2026-1784856030, CLSA-2026-1785291241, DEBIAN-CVE-2026-14257, ECHO-1a3b-6a3e-53f3, GHSA-mh99-v99m-4gvg, MINI-2584-j8m7-m58c, MINI-2cj8-q4x6-v9c9, MINI-2qvj-737c-9hcj, MINI-3769-23ww-7j8h, MINI-489w-f6f2-295j, MINI-5f33-qfw7-x4v2, MINI-5h56-7x4q-7qx2, MINI-62f2-558m-jm92, MINI-6pv2-fr5x-2qg9, MINI-7464-352r-rpc5, MINI-76g8-c88p-w669, MINI-8fvf-rrjw-cm3x, MINI-8w8m-wh35-ffgq, MINI-95mq-g4wf-6gmj, MINI-9cw2-mp5q-c39w, MINI-cmxr-pq5c-6q5v, MINI-fjpx-2jvj-g9p9, MINI-gvhw-vm5q-pgr6, MINI-gxjw-79mr-4qh5, MINI-gxvg-xx7v-7359, MINI-h3p6-28jm-hvgj, MINI-hcpg-mp79-cm5r, MINI-hw79-m36g-crm3, MINI-j8g5-37rp-hxvm, MINI-jfpx-vmcm-qv4p, MINI-jg9w-mw8j-rpxh, MINI-jv68-jgff-5mm6, MINI-jv9c-4v7m-gxgc, MINI-m4fr-mf53-hwxp, MINI-mm2g-wfq4-28x2, MINI-mr7f-r28p-v99p, MINI-p3p5-g6hc-cxw5, MINI-pcp7-ph4v-xj78, MINI-pgwf-4972-rjmm, MINI-qmgm-chgr-x89r, MINI-qr48-7rch-rj9w, MINI-r3c9-hq6p-c9jc, MINI-r96p-wph7-pq72, MINI-rc2x-cmrw-3fwp, MINI-v2pm-vh2j-47j3, MINI-v5gv-xhq7-q9m8, MINI-v5p6-jhpm-6qr3, MINI-vf9h-7cm7-w6rw, MINI-vmrr-4ffg-qj9x, MINI-vvcp-62q8-3fx7, MINI-wf29-2rjm-22cc, MINI-wq8f-vqvm-98gq, MINI-x8mg-fc38-5587, ROOT-APP-NPM-CVE-2026-14257, UBUNTU-CVE-2026-14257

## What is CVE-2026-14257?

CVE-2026-14257 is a high-severity denial of service vulnerability in juliangruber brace-expansion, published on 23 Jul 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.

### Official description

brace-expansion through 5.0.7 is vulnerable to denial of service via memory exhaustion. The expand() function limits the number of results with a max option (default 100,000) but does not bound the length of each result string. By chaining multiple brace groups, an attacker keeps the result count under the limit while making each result progressively longer, so total memory scales with both count and string length until the process hits a fatal, uncatchable out-of-memory error. About 7.5 KB of input ('{a,b}'.repeat(1500)) crashes a default Node.js process. Any application that passes attacker-influenced strings to brace-expansion.expand() - directly or transitively via minimatch / glob brace patterns - can be crashed by a small request. Fixed in 5.0.8 by adding a maxLength option (default 4,000,000) that bounds accumulated output and intermediate arrays.

Weakness: CWE-770 (Allocation of Resources Without Limits or Throttling), CWE-400 (Uncontrolled Resource Consumption)

## Which versions are affected by CVE-2026-14257?

8 open source packages ship an affected version, including brace-expansion. It affects 1 product.


| Package | Ecosystem | Affected | Fixed in |
| --- | --- | --- | --- |
| `brace-expansion` | npm | All versions | 1.1.17 |
| `brace-expansion` | npm | All versions | 1.1.17 |
| `brace-expansion` | npm | From 2.0.0 | 2.1.3 |
| `brace-expansion` | npm | From 2.0.0 | 2.1.3 |
| `brace-expansion` | npm | From 3.0.0 | 3.0.3 |
| `brace-expansion` | npm | From 3.0.0 | 3.0.3 |
| `brace-expansion` | npm | From 4.0.0 | 5.0.8 |
| `brace-expansion` | npm | From 4.0.0 | 5.0.8 |

Products: Juliangruber Brace-Expansion.

## How do I fix CVE-2026-14257?

Upgrade brace-expansion to a fixed version for your release line: 1.1.17, 2.1.3, 3.0.3 or 5.0.8.

## Is CVE-2026-14257 being exploited?

There is no known exploitation of CVE-2026-14257 in the wild and no public exploit code.

## Other vulnerabilities in juliangruber brace-expansion

- [CVE-2026-69152](https://insights.sbomify.com/CVE-2026-69152/): brace-expansion: DoS via unbounded intermediate arrays, bypassing the CVE-2026-14257 mitigation (high 7.5)
- [CVE-2026-45149](https://insights.sbomify.com/CVE-2026-45149/): brace-expansion: Large numeric range defeats documented `max` DoS protection (medium 6.5)
- [CVE-2026-33750](https://insights.sbomify.com/CVE-2026-33750/): brace-expansion: Zero-step sequence causes process hang and memory exhaustion (medium 6.5)

## Fix prompt for AI coding agents

```text
Check this codebase for CVE-2026-14257 and fix it if it is affected.

What it is: CVE-2026-14257 is a high-severity denial of service vulnerability in juliangruber brace-expansion, published on 23 Jul 2026. An attacker can exploit it over the internet without logging in, with no action from the victim.
Exploitation: There is no known exploitation of CVE-2026-14257 in the wild and no public exploit code.

Affected packages and fixed versions:
- brace-expansion (npm): affected all versions; fixed in 1.1.17
- brace-expansion (npm): affected all versions; fixed in 1.1.17
- brace-expansion (npm): affected from 2.0.0; fixed in 2.1.3
- brace-expansion (npm): affected from 2.0.0; fixed in 2.1.3
- brace-expansion (npm): affected from 3.0.0; fixed in 3.0.3
- brace-expansion (npm): affected from 3.0.0; fixed in 3.0.3
- brace-expansion (npm): affected from 4.0.0; fixed in 5.0.8
- brace-expansion (npm): affected from 4.0.0; fixed in 5.0.8

Task:
1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.
2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.
3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.
4. Run the tests and summarise what changed and why.
5. If nothing in the project is affected, say so and change nothing.

Reference: https://insights.sbomify.com/CVE-2026-14257/ (Markdown: https://insights.sbomify.com/CVE-2026-14257/index.md)
```

## Sources

- CVE record: https://www.cve.org/CVERecord?id=CVE-2026-14257
- NVD: https://nvd.nist.gov/vuln/detail/CVE-2026-14257
- OSV: https://osv.dev/vulnerability/CVE-2026-14257

---
From sbomify Insights: https://insights.sbomify.com/CVE-2026-14257/
Summaries are generated and may contain mistakes; the official description above is the record.
