Commit 99c9823
committed
fix(deps): nanoid 顶到 3.3.x 补丁线,清掉 GHSA-2v37-7h3g-55p8 (#6529)
OSV 门在锁文件上变红,因此对每一个 open PR 都生效,与各 PR 的改动内容无关。
本地以 osv-scanner v2.3.8(与 CI action 同版本)、同样的 `--lockfile=pnpm-lock.yaml`
参数复现:1387 个包,1 条 High(8.2)—— nanoid 3.3.16 命中
GHSA-2v37-7h3g-55p8 / CVE-2026-67213(自定义字母表在 size 为零时无限循环,
即拒绝服务),退出码 1。
公告带**两条**受影响区间:introduced:0 → fixed:3.3.17,以及
introduced:4.0.0 → fixed:5.1.6。此处只有第一条是活的:3.3.16 唯一由
postcss@8.5.25 间接引入(全锁文件仅一条 `nanoid:` 边),而四个 driver 直接声明的
nanoid ^6.0.0 高于第二条的修复线,本就不受影响。
上界按 AGENTS.md 与本块头部规则落在 target 之上的 **major 边界**(4.0.0),
⛔ 不写成 `<3.3.17` —— 那个形状会在 3.3.17 自己出公告那天当场失配
(undici 7.28.0 / brace-expansion 5.0.8 的活体标本,#4961 / #5032)。
`<4.0.0` 同时把 6.x 挡在选择器之外,正是它该待的地方。
^3.3.17 落在 postcss 自己声明的 ^3.3.16 区间内,所以这是往补丁线上的一次
dedupe,而不是把 postcss 顶过它支持的范围。
解析版本位移实测:1387 个 packages 键 + 1387 个 snapshots 键 + 746 条
importer 边,逐一比对,**只有 nanoid 3.3.16 → 3.3.18 一处**(^3.3.17 在 3.x
内浮到最新,即 npm 的 legacy dist-tag),其余零位移。改后复跑同一扫描:
No issues found,退出码 0,且 osv-scanner.toml 一字未动(仍是零豁免)。
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01BDmDsu2575gDxeMCxXhDE31 parent 61478b9 commit 99c9823
2 files changed
Lines changed: 30 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
210 | 210 | | |
211 | 211 | | |
212 | 212 | | |
| 213 | + | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
| 227 | + | |
| 228 | + | |
| 229 | + | |
| 230 | + | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
0 commit comments