Skip to content

fix(security): update minimatch for the Actions cache - #1844

Open
John-David Dalton (jdalton) wants to merge 1 commit into
v1.xfrom
fix/minimatch-cache-advisories
Open

John-David Dalton (jdalton) wants to merge 1 commit into
v1.xfrom
fix/minimatch-cache-advisories

Conversation

@jdalton

Copy link
Copy Markdown
Contributor

The Actions cache can keep finding blob directories with minimatch 11.0.9. Patch its glob walker to use the public partial-match API and drop the vulnerable 10.2.6 pin behind Dependabot alerts #373 and #493.

@cursor

cursor Bot commented Dec 4, 2026 •

Copy link
Copy Markdown

PR Summary

Medium Risk
Glob matching behavior for CI cache archives changes with minimatch 11; regression risk is mitigated by a targeted patch and new resolvePaths test, but wrong matches could affect what gets cached or restored.

Overview
Addresses Dependabot alerts on minimatch by letting @actions/glob (used by @actions/cache) resolve to minimatch 11.0.9 instead of pinning 10.2.6.

@actions/glob@0.7.0 is patched so partialMatch calls the public minimatch.match(itemPath, true) API instead of the removed internal matchOne, while keeping the existing root-path handling unchanged. The dedicated @actions/glob@0.7.0>minimatch override is removed and the patch is registered under patchedDependencies (lockfile refreshed accordingly).

A unit test exercises resolvePaths from @actions/cache with directory globs, nested */* patterns, and negation so cache save/restore path resolution still works with the patched stack.

Reviewed by Cursor Bugbot for commit 9d1df2f. Configure here.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant