npm
CVE-2026-137196
Glob : `ignore` patterns lack the braceExpandMax limit applied to `pattern`
- Severity
- Medium
- Published
- 1 Dec 2026
- Last changed
- 1 Dec 2026
- Added to UpHeron
- 1 Dec 2026
- Fixed in
- 14.0.6
- Exploit chance
- 0.8% in the next 30 daysHigher than 58% of CVEs. EPSS by FIRST, 1 Dec 2026
- Also known as
- GHSA-qxr8-q827-836c
- Sources
- OSV.dev and GitHub
Description
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.
src/glob.ts:527-529 — pattern path, limit present:
src/ignore.ts:71-83 — ignore path, limit missing:
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.
Affected software
| Software | Affected versions |
|---|---|
globnpm · osv:npm:glob |
|
About glob
- Weekly downloads (npm)
- 509,810,533npm, 1 Dec 2026
Vulnerabilities in glob
- In our list
- 2
- Published in the last 12 months
- 2
- Critical, last 12 months
- 0
- High, last 12 months
- 0
- Known exploited
- 0
- CVE-2026-118773Glob: AbortSignal cancellation bypass allows post-timeout filesystem traversalMedium 30 Oct 2026
References
- CVE.org https://www.cve.org/CVERecord?id=CVE-2026-137196
- GitHub Advisory Database https://github.com/advisories/GHSA-qxr8-q827-836c