Advisory Database
  • Advisories
  • Dependency Scanning
  1. npm
  2. ›
  3. minimatch
  4. ›
  5. CVE-2026-27903

CVE-2026-27903: minimatch has ReDoS: matchOne() combinatorial backtracking via multiple non-adjacent GLOBSTAR segments

February 26, 2026

matchOne() performs unbounded recursive backtracking when a glob pattern contains multiple non-adjacent ** (GLOBSTAR) segments and the input path does not match. The time complexity is O(C(n, k)) – binomial – where n is the number of path segments and k is the number of globstars. With k=11 and n=30, a call to the default minimatch() API stalls for roughly 5 seconds. With k=13, it exceeds 15 seconds. No memoization or call budget exists to bound this behavior.


References

  • github.com/advisories/GHSA-7r86-cg39-jmmj
  • github.com/isaacs/minimatch
  • github.com/isaacs/minimatch/commit/0bf499aa45f5059b56809cc3b75ff3eafeb8d748
  • github.com/isaacs/minimatch/security/advisories/GHSA-7r86-cg39-jmmj
  • nvd.nist.gov/vuln/detail/CVE-2026-27903

Code Behaviors & Features

Detect and mitigate CVE-2026-27903 with GitLab Dependency Scanning

Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →

Affected versions

All versions before 3.1.3, all versions starting from 4.0.0 before 4.2.5, all versions starting from 5.0.0 before 5.1.8, all versions starting from 6.0.0 before 6.2.2, all versions starting from 7.0.0 before 7.4.8, all versions starting from 8.0.0 before 8.0.6, all versions starting from 9.0.0 before 9.0.7, all versions starting from 10.0.0 before 10.2.3

Fixed versions

  • 10.2.3
  • 9.0.7
  • 8.0.6
  • 7.4.8
  • 6.2.2
  • 5.1.8
  • 4.2.5
  • 3.1.3

Solution

Upgrade to versions 10.2.3, 3.1.3, 4.2.5, 5.1.8, 6.2.2, 7.4.8, 8.0.6, 9.0.7 or above.

Impact 7.5 HIGH

CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H

Learn more about CVSS

Weakness

  • CWE-407: Inefficient Algorithmic Complexity

Source file

npm/minimatch/CVE-2026-27903.yml

Spotted a mistake? Edit the file on GitLab.

  • Site Repo
  • About GitLab
  • Terms
  • Privacy Statement
  • Contact

Page generated Tue, 24 Mar 2026 12:17:30 +0000.