Vulnerability in pnpm (CVE-2026-50021)
Summary
Vulnerability in pnpm (CVE-2026-50021). Confidential information can be exposed externally. Exploitable via integrity. Mitigation: upgrade to 10.34.1 or later.
Original description
The description as published by the source.
Summary
pnpm's tarball extraction worker skips integrity verification when the integrity field is absent from the lockfile resolution. If an attacker can both modify pnpm-lock.yaml to remove the integrity: field and cause the referenced registry URL to serve altered package content, pnpm install --frozen-lockfile can install the altered package without an integrity error. npm's npm ci enforces integrity by default; pnpm's behavior of silently skipping verification is a pnpm-specific fail-open gap.
Vulnerability Details
The addTarballToStore function in worker/src/start.ts (lines 189-204) checks if (integrity) before verifying the tarball hash. The TarballResolution type declares integrity as optional (integrity?: string). When the lockfile omits the integrity field, the guard evaluates to false, skipping hash verification entirely. The worker then computes a new hash from the unverified content and stores it as legitimate.
// worker/src/start.ts:189-204
function addTarballToStore ({ buffer, storeDir, integrity, ... }: TarballExtractMessage) {
if (integrity) { // false when integrity is undefined
const { algorithm, hexDigest } = parseIntegrity(integrity)
const calculatedHash = crypto.hash(algorithm, buffer, 'hex')
if (calculatedHash !== hexDigest) {
return { status: 'error', error: { type: 'integrity_validation_failed', ... } }
}
}
return {
status: 'success',
value: { integrity: int…
Source: GitHub Security Advisories (Global) NVD GitHub Advisory
Auto-generated summary
Assembled by SecPulse from the source data (CVSS, CWE, affected versions) using templates — no AI involved. Check the original description and references below for exact details.
A vulnerability tracked as CVE-2026-50021 has been found in pnpm.
Attackers can target a specific entry point like integrity over the network to misuse the product.
Confidential information can be exposed externally. CVSS score: 6.8/10.
What to do: upgrade pnpm to 10.34.1 or later.
If unsure, ask your IT team or search "pnpm CVE-2026-50021" on the vendor's site.
CVE-2026-50021 (pnpm) — CWE-354 / CVSS v3 6.8
Attack vector: remote (network-reachable) / no user interaction
Attack surface: integrity / addTarballToStore / TarballResolution / false
Patched: 10.34.1 — apply immediately
Plan: 1) Audit SBOM/dependencies, 2) Stage→prod upgrade, 3) Add WAF/proxy monitoring on affected endpoints, 4) Hunt IOCs in logs.
Refs: see the GHSA / vendor advisory / patched release linked on this page.
A vulnerability (CWE-354) exists in pnpm. Attackers reach the vulnerable code path via integrity.
Check the vendor advisory for the affected versions of pnpm. Attack surface: integrity / addTarballToStore / TarballResolution / false.
Severity: Medium (CVSS 6.8/10). Confidential information can be exposed externally.
Update to 10.34.1.
Until the patch is applied: disable the affected feature, apply WAF rules, or restrict access via network ACLs.
Search webserver/proxy logs for unusual request patterns matching this CVE's known IOCs. Run grep -r 'pnpm' . against your dependency files (package-lock.json, requirements.txt, go.sum) to find affected services.
Response actions
Concrete steps and command examples for SOC/SRE teams to execute in order
-
1Identify exposure identify
grep -r 'pnpm' . | grep -v node_modulesリポジトリと本番環境の依存ファイル (package-lock.json / requirements.txt / go.sum / Gemfile.lock 等) で
pnpmを grep し、稼働しているサービス・バージョンを把握する。 -
2Apply patch patch
Upgrade pnpm to 10.34.1ステージング環境で 10.34.1 に上げて回帰テスト → 本番反映。回帰テストはアプリの主要ハッピーパスを含めること。
-
3Post-deployment verification verify
Confirm patched version is live in productionパッチ適用後、ステージングで PoC または同等の悪用パターンを再現して脆弱性が閉じたことを確認。本番ではアクセスログ・WAF でアラート再発が無いか継続監視。
Affected packages
References
- advisory nvd.nist.gov
- package github.com
- web github.com
- web github.com