Skip to content

build(security): retarget stale overrides and refresh transitive deps flagged by pnpm audit - #643

Merged
Ducksss merged 1 commit into
mainfrom
claude/audit-transitive-2026-10-29
Oct 30, 2026
Merged

Ducksss merged 1 commit into
mainfrom
claude/audit-transitive-2026-10-29

Conversation

@Ducksss

@Ducksss Ducksss commented Oct 29, 2026 •

Copy link
Copy Markdown
Owner

Why

pnpm audit on main reports 31 advisories (2 critical, 12 high, 13 moderate, 4 low). This morning GitHub's alert list showed only 3 of them. It caught up when main moved at 09:21 UTC and now shows 25, but it still misses zod, body-parser, ip-address and one of the MCP SDK advisories.

Two of the gaps are our own pnpm overrides that went stale. In both, the exact target now sits inside the widened advisory range:

  • fast-uri@<3.1.8: 3.1.8 against an advisory now covering <3.1.9. fast-uri arrives through ajv, one of the two dependencies the published CLI ships.
  • qs@<6.16.0: 6.16.0 against an advisory now covering <=6.16.0.

What changed

Package Advisories From To How
fast-uri (via ajv) 4 (2 moderate, 2 low) 3.1.8 3.1.9 Override retargeted: fast-uri@<3.1.9: 3.1.9
qs (via express) 1 moderate 6.16.0 6.16.1 Override retargeted: qs@<6.16.1: 6.16.1
undici (via shadcn, jsdom, dotenvx) 8 (high, moderate) 7.30.0 7.30.1 Lockfile-only
body-parser (via express) 1 high 2.3.0 2.4.0 Lockfile-only
systeminformation (via dotenvx) 3 (high, moderate, low) 5.33.1 5.33.16 Lockfile-only
@hono/node-server (via MCP SDK) 1 moderate 2.1.1 2.1.3 Lockfile-only
ip-address (via express-rate-limit, socks) 1 moderate 10.7.2 10.7.4 Lockfile-only
zod (root devDependency) 1 high 4.4.3 4.6.7 package.json bump
zod (fumadocs-mdx's copy) same 4.6.5 4.6.7 Lockfile-only
happy-dom (optional vitest peer) 3 (high, moderate) 20.9.0 removed Lockfile-only
ws (only happy-dom used it) none 8.21.0 removed Dead ws@>=8.0.0 <8.21.0 override deleted

Notes:

  • Versions. Each target is the first release that clears every advisory open against its package, and each has been on npm for at least a week. systeminformation needs 5.33.16, not 5.33.14, because one of its three advisories runs to <5.33.16. zod goes to 4.6.7 rather than 4.6.6 because ci(deps-dev): bump the five open Dependabot npm groups in one lockfile, refresh the MCP SDK #641's fumadocs-mdx 15.4.9 already resolves 4.6.7. Using the same version keeps a single zod 4 copy once both PRs land.
  • Lockfile-only. For these packages every parent's declared range already admits the fix, checked against the original manifests in the .pnpm store. Each was moved with a temporary override, then pnpm install, then the override removed and a second pnpm install. The zod pins were scoped to their parents (fumadocs-mdx>zod, eslint-plugin-react-hooks>zod) so the MCP SDK's zod 3 edge doesn't move. A package-level diff of the lockfile's packages: section shows only the packages in the table, plus happy-dom's own dependencies (@types/whatwg-mimetype, @types/ws, bufferutil, utf-8-validate, node-gyp-build, entities@7, whatwg-mimetype@3), which left with it. pnpm update --depth Infinity was not used, because it also moves unrelated packages.
  • happy-dom. vitest declares it as an optional * peer, and the repo runs vitest with environment: 'node' and never imports it. Once the lockfile entry was disturbed, pnpm (autoInstallPeers skips optional peers) dropped it instead of bumping it. With it went the only ws in the tree, so the ws override no longer matched anything and was removed. A future vitest that pulls happy-dom back would resolve a current, patched release.
  • Overrides. A liveness pass over the whole override block shows every remaining entry still matches at least one dependent's declared range. The two retargeted entries rewrite only ajv's ^3.0.1 and express's ^6.14.0, and both forced versions satisfy those ranges. body-parser 2.4.0 no longer depends on qs. The lockfile's overrides: section matches package.json, and pnpm install --frozen-lockfile passes.
  • Consumers. Overrides are lockfile-local. CLI consumers resolve ajv's own ^3.0.1 and already get a current fast-uri. The fast-uri fix is for this repo's tree.

Left as is

Package Advisory Why
zod 3.25.76 via shadcn 4.18.0 (^3.24.1) GHSA-mrhx-c7xc-m3w5 (high, <4.6.6) zod has no patched 3.x. Overriding to zod 4 would break shadcn 4.18 on import: its schema module calls .deepPartial(), which zod 4 removed, and it reads ZodError.errors. The fix is shadcn 4.22.0 or later (zod ^4.2.0), a direct devDependency upgrade for its own PR. GitHub has no alert for it.
deepmerge 4.3.1 via shadcn GHSA-gcqx-w48m-w2h4 (low) No patched version exists. Alert #168 stays open.

Fixed by #641, not here: next 16.4.0 → 16.4.2 (GHSA-2464-fhr4-w9xw and GHSA-673q-mjm6-r5xr, both critical unauthenticated RCE, plus GHSA-p3m5-59mp-jv5r, high) and @modelcontextprotocol/sdk 1.31.0 → 1.32.2 (4 advisories).

Audit counts

Tree Advisories
main (62b7789) 31: 2 critical, 12 high, 13 moderate, 4 low
this branch 9: next ×3 and MCP SDK ×4 (#641), shadcn's zod 3, deepmerge
this branch merged onto #641's head 2: shadcn's zod 3 (high) and deepmerge (low)

The last row comes from a scratch merge onto #641's head. package.json merged cleanly. I took #641's lockfile and re-ran the same temporary-override recipe, and it reproduced the same package moves.

#641 interaction

Both PRs rewrite pnpm-lock.yaml, so whichever merges second needs a lockfile rebase. If #641 lands first, rebase this branch: take main's lockfile, pnpm install, add the temporary pins, pnpm install, remove them, pnpm install again. The scratch merge above shows that path gives the 2-advisory result.

Checks

Run locally on this branch (rebased on 62b7789):

  • pnpm install --frozen-lockfile, pnpm source:build, pnpm exec tsc --noEmit, pnpm lint, prettier on package.json: clean.
  • pnpm test:int: 872 passed, 1 skipped (67 files)
  • pnpm test:pack: passed (the packed CLI installs with only ajv and semver)

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Chores
    • This update includes no changes to app features or behavior visible to users. There are no new capabilities, interface updates, or user-facing fixes to call out in these release notes.

@vercel

vercel Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated
payload-components Ready Ready Preview Oct 30, 2026 11:03am UTC

Copilot AI balanced review requested due to automatic review settings October 29, 2026 09:32
@coderabbitai

coderabbitai Bot commented Oct 29, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

No actionable comments were generated in the recent review.

Recent review info
Run configuration
Commits

Reviewing files that changed from the base of the PR and between 193c0ab and a77dc8a.

Files ignored due to path filters: 1
  • pnpm-lock.yaml is excluded by !**/pnpm-lock.yaml
Files selected for processing: 1
  • package.json

Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review.

Walkthrough

The package manifest updates the Zod development dependency, raises the minimum versions targeted by the fast-uri and qs overrides, and removes the ws override.

Changes: Dependency Version Updates

Layer / File(s) Summary
Development dependency and override updates
package.json
The Zod development dependency changes from 4.4.3 to 4.6.7. The override thresholds for fast-uri and qs increase. The ws override is removed.

Priority: Low

Estimated code review effort: 2 (Simple) | ~5 minutes

Change: Other

Merge Risk: Minimal · up to a77dc

No actionable merge-blocking issue is established for these dependency updates. Merge after normal dependency installation and validation checks pass.

Pre-merge checks: Passed 5
Check name Status Explanation
Title check Passed The title clearly and concisely describes the dependency security updates, override changes, and transitive dependency refresh.
Description check Passed The description is detailed and directly covers the motivation, dependency changes, remaining advisories, verification results, and lockfile merge considerations. It does not use the exact template he…
Docstring Coverage Passed No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentat…
Linked Issues check Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check Passed Check skipped because no linked issues were found for this pull request.
Full details: Description check

Explanation

The description is detailed and directly covers the motivation, dependency changes, remaining advisories, verification results, and lockfile merge considerations. It does not use the exact template headings or report pnpm test:release, but the required change context and verification information are mostly complete.

Full details: Docstring Coverage

Explanation

No eligible functions found in the changed files. Skipping docstring coverage check. Docstring coverage is scoped to functions touched by this diff with cyclomatic complexity of at least 2. Documentation-only edits and deletions within surviving functions are included; unchanged diff context and fully deleted functions are excluded. Analyzed 0 functions across 0 files. (1 skipped: 1 unsupported.)

Finishing Touches
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota.

… flagged by pnpm audit

pnpm audit reported advisories that GitHub's alert list does not show.

- Retarget the stale overrides: fast-uri@<3.1.9 -> 3.1.9 (ajv, ships
  with the CLI) and qs@<6.16.1 -> 6.16.1. Both old targets were inside
  the widened advisory ranges.
- Bump the root zod devDependency 4.4.3 -> 4.6.7, the version #641's
  fumadocs-mdx already resolves, so the tree keeps one zod 4 copy.
- Lockfile-only refresh, every parent range already admits the fix:
  undici 7.30.1, body-parser 2.4.0, systeminformation 5.33.16,
  @hono/node-server 2.1.3, ip-address 10.7.4, and the fumadocs-mdx /
  eslint-plugin-react-hooks zod copies to 4.6.7.
- happy-dom (an optional vitest peer the repo never loads) drops out of
  the lockfile, taking ws with it, so the now-dead ws override goes too.

Left as is: shadcn 4.18.0's zod 3.25.76 (zod has no patched 3.x and
shadcn 4.18 calls .deepPartial(), which zod 4 removed) and deepmerge
4.3.1 (no patched version).

Rebuilt on a37ec27/193c0ab3 after #641 landed: the same package.json edits and
temporary-pin recipe, applied to the new lockfile. The package-level diff matches
the original except that fumadocs-mdx's zod was already at 4.6.7 via #641.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@Ducksss
Ducksss force-pushed the claude/audit-transitive-2026-10-29 branch from 1373460 to a77dc8a Compare October 30, 2026 10:47
@Ducksss
Ducksss merged commit c5d94a1 into main Oct 30, 2026
17 checks passed
@Ducksss
Ducksss deleted the claude/audit-transitive-2026-10-29 branch October 30, 2026 11:14
Ducksss added a commit that referenced this pull request Oct 30, 2026
…e, keep a single motion (#646)

#637, #639, #644 and #645 all rewrite pnpm-lock.yaml and conflict with each
other and with main after #643, so they are folded into one pnpm install:

- next, eslint-config-next 16.4.2 -> 16.4.3 (#645)
- vite 8.3.4 -> 8.3.5 (#644)
- fumadocs-core, fumadocs-ui 16.17.7 -> 16.17.8; fumadocs-mdx 15.4.9 -> 15.4.10 (#639)
- lucide-react 1.58.0 -> 1.62.0 (#637)

fumadocs-ui 16.17.8 raises its motion range from ^14.0.0 to ^14.6.0, which the
site's exact motion 14.0.0 can't satisfy, so on its own the bump would bring
back the second motion runtime that #619 removed (14.8.0 next to 14.0.0). The
site's motion moves to 14.7.0, the newest release more than three days old, and
the lockfile keeps one copy of motion, framer-motion, motion-dom and
motion-utils. The five motion components already declare ^14.0.0, so no
manifest changes. The @radix-ui/* minor bumps come in through fumadocs-ui
16.17.8.

Co-authored-by: Claude Opus 5.5 <[email protected]>

This branch was successfully deployed

1 active deployment
Preview — a77dc8af Deployed Oct 30, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants