Uncontrolled Recursion Affecting brace-expansion package, versions <1.1.20>=2.0.0 <2.1.6>=3.0.0 <3.0.8>=4.0.0 <5.0.11


Severity

Recommended
0.0
high
0
10

CVSS assessment by Snyk's Security Team. Learn more

Threat Intelligence

EPSS
0.35% (27th percentile)

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk IDSNYK-JS-BRACEEXPANSION-20244948
  • published29 Sept 2026
  • disclosed28 Sept 2026
  • creditGareth Jones, Jeremy Katz

Introduced: 28 Sep 2026

NewCVE-2026-102278  (opens in a new tab)
CWE-674  (opens in a new tab)

How to fix?

Upgrade brace-expansion to version 1.1.20, 2.1.6, 3.0.8, 5.0.11 or higher.

Overview

brace-expansion is a Brace expansion as known from sh/bash

Affected versions of this package are vulnerable to Uncontrolled Recursion via uncontrolled recursion in expand_ when processing deeply nested brace patterns. An attacker can supply approximately 6 KB of deeply nested braces (e.g., { repeated ~3,200 times followed by a,b and the matching } characters) to exhaust the native call stack and crash the process with a RangeError: Maximum call stack size exceeded. The max and maxLength bounds do not prevent this because the stack is exhausted during recursive descent into sub-expansions, before the result set grows.

CVSS Base Scores

version 4.0
version 3.1