Skip to content

chore: pin @tanstack router deps to non-malicious versions#483

Merged
gabitoesmiapodo merged 2 commits into
developfrom
chore/482-tanstack-router-supply-chain-patch
May 12, 2026
Merged

chore: pin @tanstack router deps to non-malicious versions#483
gabitoesmiapodo merged 2 commits into
developfrom
chore/482-tanstack-router-supply-chain-patch

Conversation

@gabitoesmiapodo
Copy link
Copy Markdown
Collaborator

Summary

Refs #482

Important

Interim mitigation, not the final fix. The patched versions named in GHSA-g7cv-rxg3-hmpx (@tanstack/react-router@1.169.9, react-router-devtools@1.166.20, router-cli@1.166.50, router-plugin@1.167.42) are not yet published to npm as of 2026-05-12 (npm view returns 404; the registry tops out below the malicious window). This PR therefore pins direct deps to exact current latest non-malicious builds to neutralise the ^-drift exposure today. Issue #482 must remain open until the GHSA-listed patched versions land on npm; a follow-up PR will move the pins to those versions then.

Replaces ^ ranges on the four direct @tanstack/* router deps with exact pins so future fresh resolutions (deleted lockfile, pnpm update, Renovate/Dependabot) cannot land on the malicious 2026-05-11 supply-chain compromise window (CVE-2026-45321 / GHSA-g7cv-rxg3-hmpx).

Changes

  • @tanstack/react-router: ^1.168.101.169.2 (exact)
  • @tanstack/react-router-devtools: ^1.166.111.166.13 (exact)
  • @tanstack/router-cli: ^1.166.251.166.43 (exact)
  • @tanstack/router-plugin: ^1.167.121.167.35 (exact)
  • Regenerated pnpm-lock.yaml; all 10 affected @tanstack/* entries (direct + transitive) verified below their respective malicious windows.

Acceptance criteria

Mirroring the issue. Items prefixed with [interim] are completed by this PR; items prefixed with [follow-up] are intentionally deferred until TanStack publishes the GHSA-listed patched versions and remain owned by #482.

  • [follow-up] Bump direct deps in package.json to the patched releases (or higher):
    • @tanstack/react-router^1.169.9
    • @tanstack/react-router-devtools^1.166.20
    • @tanstack/router-cli^1.166.50
    • @tanstack/router-plugin^1.167.42
  • [interim] Regenerate pnpm-lock.yaml and confirm no transitive @tanstack/* version falls in a vulnerable range.
  • [interim] Run pnpm wagmi-generate, pnpm routes:generate, pnpm lint, pnpm test, and pnpm build to confirm the bump is non-breaking.
  • [interim] Pin direct deps to exact current-latest non-malicious versions to prevent ^-drift while patched versions are unavailable on npm.

Test plan

Automated tests

No automated tests added (dependency-only change). Existing suite re-run as regression coverage.

  • pnpm lint — clean
  • pnpm test — 213/213 passing
  • pnpm buildtsc --noEmit + vite build succeeded
  • pnpm routes:generaterouteTree.gen.ts regenerates cleanly under new router-cli/router-plugin/router-generator versions

Manual verification

  • pnpm dev and navigate between at least two routes to confirm TanStack Router still mounts at runtime.
  • Inspect pnpm-lock.yaml and confirm no @tanstack/* entry resolves into a malicious window:
    • react-router / router-core: not 1.169.51.169.8
    • react-router-devtools: not 1.166.161.166.19
    • router-cli: not 1.166.461.166.49
    • router-generator: not 1.166.451.166.48
    • router-plugin: not 1.167.381.167.41
    • router-devtools-core: not 1.167.61.167.9
    • history: not 1.161.91.161.12
    • router-utils: not 1.161.111.161.14
    • virtual-file-routes: not 1.161.101.161.13

Breaking changes

None.

Checklist

  • Self-reviewed my own diff
  • Tests added or updated
  • Docs updated (if applicable)
  • No unrelated changes bundled in

Screenshots

None.

Interim mitigation for GHSA-g7cv-rxg3-hmpx / CVE-2026-45321. The advisory's
patched versions (react-router 1.169.9, react-router-devtools 1.166.20,
router-cli 1.166.50, router-plugin 1.167.42) are not yet published to npm.
Replace ^ ranges with exact pins on the current latest non-malicious builds
to neutralise the caret-drift exposure on fresh resolutions until the
patched releases land:

- @tanstack/react-router: ^1.168.10 -> 1.169.2
- @tanstack/react-router-devtools: ^1.166.11 -> 1.166.13
- @tanstack/router-cli: ^1.166.25 -> 1.166.43
- @tanstack/router-plugin: ^1.167.12 -> 1.167.35

All transitive @tanstack/* lockfile entries verified to sit below the
malicious windows after pnpm install. Lint, tests (213/213), and build
all pass.

Refs #482
Copilot AI review requested due to automatic review settings May 12, 2026 16:30
@gabitoesmiapodo gabitoesmiapodo self-assigned this May 12, 2026
@vercel
Copy link
Copy Markdown

vercel Bot commented May 12, 2026

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

Project Deployment Actions Updated (UTC)
components.dappbooster Ready Ready Preview, Comment May 12, 2026 5:06pm
demo.dappbooster Ready Ready Preview, Comment May 12, 2026 5:06pm
docs.dappbooster Ready Ready Preview, Comment May 12, 2026 5:06pm

Request Review

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Pins TanStack Router-related direct dependencies to exact currently-available non-malicious versions to prevent caret-range drift into the reported compromised version windows, and regenerates the pnpm lockfile accordingly.

Changes:

  • Replace ^ ranges with exact pins for @tanstack/react-router, @tanstack/react-router-devtools, @tanstack/router-cli, and @tanstack/router-plugin.
  • Regenerate pnpm-lock.yaml so the resolved tree reflects the pinned router packages and updated safe transitive versions.

Reviewed changes

Copilot reviewed 1 out of 2 changed files in this pull request and generated no comments.

File Description
package.json Pins the four direct TanStack Router packages to exact safe versions to avoid future ^ drift.
pnpm-lock.yaml Updates lockfile to match the pinned versions and refreshed transitive resolutions.
Files not reviewed (1)
  • pnpm-lock.yaml: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@gabitoesmiapodo gabitoesmiapodo merged commit 10faa5f into develop May 12, 2026
4 of 7 checks passed
@gabitoesmiapodo gabitoesmiapodo deleted the chore/482-tanstack-router-supply-chain-patch branch May 12, 2026 17:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants