TanStack GitHub Actions Trusted Publisher Supply Chain Compromise
CVE-2026-45321 tracks a supply-chain compromise affecting 42 @tanstack/* npm packages, where 84 malicious versions were published to npm on 2026-05-11 between approximately 19:20 and 19:26 UTC. The available reporting indicates the attacker did not modify the publish workflow itself and did not rely on stolen npm maintainer tokens; instead, they abused TanStack’s legitimate GitHub Actions trusted-publisher/OIDC release path. The attack chain combined three weakness classes: a pull_request_target workflow misconfiguration that allowed fork-controlled code to execute in a privileged base-repository context, GitHub Actions cache poisoning across the fork-to-base trust boundary, and runtime extraction of the GitHub Actions OIDC token from runner process memory. The stolen OIDC token was then exchanged through npm trusted publishing to obtain publish capability under TanStack’s trusted identity, resulting in malicious package releases that reportedly carried valid provenance attestations. The published packages contained credential-stealing malware intended to execute during package installation and harvest developer, CI/CD, cloud, and related secrets.
Are you exposed to this one?
Mallory correlates every CVE against your assets, your vendors, and active adversary campaigns. Know which vulnerabilities matter for you, not just which ones are loud.
Impact, mitigation & remediation
What it means. What to do now. Patch path, mitigations, and the assume-compromise checklist.
Impact
What an attacker gets, and what they’ve been doing with it.
Mitigation
If you can’t patch tonight, do this now.
Remediation
Patch, then assume compromise.
Exploits
2 valid exploits after Mallory filtered fakes, detection scripts, and README-only repos (10 hidden).
This repository is a small educational lab that simulates an npm supply-chain attack associated with CVE-2026-45321/TanStack-themed compromise scenarios. It is not a full offensive toolkit; instead, it demonstrates how a malicious package can achieve install-time code execution through the npm `postinstall` lifecycle hook and how similar behavior could affect CI/CD pipelines. Repository structure: `attacker-package/` contains the core exploit logic, including `package.json` and `payload.js`; `fake-repo/` contains a GitHub Actions workflow simulation (`test.yml`) showing how CI could invoke installation of the malicious package; `victim-project/` is a placeholder directory representing the victim environment. The main exploit capability resides in `attacker-package/package.json`, which defines `postinstall: node payload.js`, causing `payload.js` to run automatically when the package is installed. The payload itself is simple but functional: it imports Node's `os` and `fs` modules, prints a marker string indicating execution, collects `USER`, hostname, and platform information, and writes that data to `loot.txt`. There is no network exfiltration, persistence, privilege escalation, or remote command-and-control in the provided code. As such, the exploit is operational as a local proof of install-time execution, but the payload is basic and hardcoded. The CI/CD simulation in `fake-repo/test.yml` uses a `pull_request_target` workflow and demonstrates how an install step could execute attacker-controlled package code on a GitHub Actions runner. This reinforces the repository's purpose as a supply-chain and CI/CD abuse demonstration rather than a stealthy real-world malware sample.
This repository is a small educational proof-of-concept simulating an npm supply-chain compromise associated with CVE-2026-45321 and a TanStack-themed package name. The repo contains 5 files: a README, a GitHub Actions workflow snippet (`download (2)`), an npm lockfile-like JSON (`download (7)`), a package manifest mislabeled as `payload.js`, and a JavaScript payload mislabeled as `tanstack-react-router-1.169.5.tgz`. Despite the filename/content mismatch, the intended structure is clear from the README. Core exploit behavior: the malicious package impersonates `@tanstack/react-router` version `1.169.5` and defines a `postinstall` script (`node payload.js`). When the victim installs the tarball, npm executes the lifecycle hook automatically. The payload then collects simple host metadata (`USER`, hostname, platform), prints a marker string (`=== MALICIOUS PAYLOAD EXECUTED ===`), and writes the data to `loot.txt`. This demonstrates install-time arbitrary code execution rather than remote exploitation. The repository does not contain a full offensive framework and is not a detection script. It is an operational PoC because it includes a working payload, though the payload is basic and hardcoded. The main attack vectors are supply-chain compromise of a dependency, CI/CD execution through GitHub Actions `pull_request_target` workflows that run `npm install`, and local file-based package installation via a tarball path. No external C2, exfiltration endpoint, or network beaconing is present in the code; all observable actions are local file writes and console output. Notable endpoints and artifacts include the local tarball path `../attacker-package/tanstack-react-router-1.169.5.tgz`, the output file `loot.txt`, the lifecycle command `node payload.js`, and references to GitHub, NVD, npm, and GitHub Actions documentation. Overall, the repository’s purpose is to demonstrate how a malicious npm package can abuse lifecycle hooks to gain code execution during dependency installation, especially in developer or CI environments that implicitly trust package installs.
Affected products & vendors
Products and vendors Mallory has correlated with this vulnerability. Open in Mallory to drill down to specific CPE configurations and version ranges.
Vendor-confirmed product mapping. Mallory continuously reconciles this list against your asset inventory.
Recent activity
40 sources tracked across advisories, community write-ups, and news. New activity surfaces here as Mallory finds it.
A vulnerability/tracking identifier associated with the TanStack / Mini Shai-Hulud supply-chain compromise that CISA added to KEV and set a remediation deadline for.
A specific vulnerability identifier referenced in connection with prior TeamPCP targeting of TanStack packages; the content does not provide technical details beyond the CVE ID and CVSS score.
A supply chain attack affecting TanStack npm packages where attackers abused GitHub Actions to publish numerous malicious package versions containing credential-stealing malware.
A supply chain attack on 42 @tanstack npm packages in which attackers abused GitHub Actions, cache poisoning, pull_request_target misconfiguration, and OIDC token theft to publish malicious package versions containing credential-stealing malware.
The version that knows your environment.
Query your assets running an affected version, and investigate the blast radius.
Every observed campaign linking this CVE to a named adversary.
Malware families riding this exploit, with evidence and IOCs.
YARA, Sigma, Snort, and vendor rules, auto-deployed to your SIEM.
Cross-references every affected SKU, including bundled OEM variants.
Community discussion across Reddit, Mastodon, and other social sources.