Commit b978e15
ci: harden .npmrc (release-age cooldown + block git-URL deps) (#29)
* ci: add 7-day npm release-age cooldown (.npmrc min-release-age)
npm has no default cooldown (unlike pnpm@11). Set min-release-age=7
so resolution only picks versions published >=7 days ago, giving
time for malicious releases to be caught/yanked before install.
CI already uses --ignore-scripts and package-lock=false, so this
gates every resolve. Per the TanStack/Snyk supply-chain advisory.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
* ci: block git-URL deps (.npmrc allow-git=none)
Git dependencies can ship a .npmrc that overrides the git executable
path, enabling arbitrary code execution at install (the actual
TanStack attack vector). npm CLI 11.10+ supports allow-git=none, and
v12 is expected to make it the default. No current dep uses a git URL.
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>1 parent 01a5209 commit b978e15
1 file changed
Lines changed: 11 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
0 commit comments