Files
pnpm/pkg-manager/core/test
Zoltan Kochan 78e29fe558 fix(security): backport lockfile & manifest name/slot containment to v10 (#12890)
Backports the TypeScript portion of 51300fd41c (#12872) to release/10.
Two advisories:

- GHSA-c59q-g84q-2gj5: lockfile depPath name -> isolated linker + PnP.
- GHSA-vq4v-j7r6-jq4m: dependency manifest `name` from the fetched
  tarball (e.g. @x/../../../path) -> resolver/linker.

Apply safeJoinModulesDir at lockfileToDepGraph (deps/graph-builder) and
the PnP packageLocation (lockfile-to-pnp); validate manifest names in
resolve-dependencies (extendGraph + resolvePeers); contain the
global-virtual-store slot dir by rejecting a traversal version segment
in iterateHashedGraphNodes (calc-dep-state), the single point every GVS
slot path funnels through.

The pacquet and env-installer changes from the original commit do not
apply to v10 (no pacquet stack; installConfigDeps has no GVS subdep
installation and config-dependency names are already validated by
assertValidConfigDepName from #12504).

All rejections surface ERR_PNPM_INVALID_DEPENDENCY_NAME.

Co-authored-by: Claude Fable 5 <noreply@anthropic.com>
2026-07-10 01:50:19 +02:00
..