{"id":"GHSA-g3hv-75wg-m249","summary":"minimatch has potential denial of service via globparts amplification","details":"minimatch 10.2.6 contains an attacker-controlled pattern amplification in firstPhasePreProcess() when optimizationLevel \u003e= 2.\n\nresearcher: Reid Downing (b1nv0id)\nfiles: \n\n- src/index.ts: 690-770\n- src/index.ts: 780-796\n\nissue:\ninput-controlled growth of globParts during first-phase preprocessing, followed by quadratic second-phase processing.\n\nthe **/../ transformation clones a globparts entry and appends the clone to the same globparts array:\n```\nparts.splice(gs, 1)\nconst other = parts.slice(0)\nother[gs] = '**'\nglobParts.push(other)\n```\nthis occurs inside a do...while (didSomething) fixpoint loop, allowing generated entries to be processed again.\n\nthe expanded globparts array is subsequently processed by secondPhasePreProcess(), which performs pairwise comparisons:\n```\nfor (let i = 0; i \u003c globParts.length - 1; i++) {\n  for (let j = i + 1; j \u003c globParts.length; j++) {\n    this.partsMatch(...)\n  }\n}\n```\nan attacker who can supply a glob pattern can therefore cause additional pattern entries to be generated during preprocessing, followed by quadratic pairwise processing, resulting in excessive cpu and memory consumption.","aliases":["CVE-2026-118764"],"modified":"2026-10-30T23:15:07.420159385Z","published":"2026-10-30T23:09:55Z","database_specific":{"github_reviewed_at":"2026-10-30T23:09:55Z","nvd_published_at":"2026-10-29T17:18:07Z","cwe_ids":["CWE-405"],"severity":"MODERATE","github_reviewed":true},"references":[{"type":"WEB","url":"https://github.com/isaacs/minimatch/security/advisories/GHSA-g3hv-75wg-m249"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-118764"},{"type":"WEB","url":"https://github.com/isaacs/minimatch/commit/77a0f5c4b80bdc641c3c930a1d9edf5ad2db57f8"},{"type":"PACKAGE","url":"https://github.com/isaacs/minimatch"},{"type":"WEB","url":"https://github.com/isaacs/minimatch/releases/tag/v11.0.1"}],"affected":[{"package":{"name":"minimatch","ecosystem":"npm","purl":"pkg:npm/minimatch"},"ranges":[{"type":"SEMVER","events":[{"introduced":"0"},{"fixed":"11.0.1"}]}],"database_specific":{"source":"https://github.com/github/advisory-database/blob/main/advisories/github-reviewed/2026/10/GHSA-g3hv-75wg-m249/GHSA-g3hv-75wg-m249.json"}}],"schema_version":"1.9.2","severity":[{"type":"CVSS_V4","score":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:N/VA:L/SC:N/SI:N/SA:N"}]}