Sending Logs, Alerts, and Telemetry Through a Data Diode

Find Out How
We utilize artificial intelligence for site translations, and while we strive for accuracy, they may not always be 100% precise. Your understanding is appreciated.

Mini Shai-Hulud: TanStack, OpenAI, and the npm Supply Chain Trap

The self-propagating worm once again rode through trusted packages and pipelines.
By Lavinia Prejban, Product Marketing Specialist
Share this Post

The latest supply chain campaign didn't just compromise open-source registries. It hijacked the release pipeline inside one of the most security-conscious organizations in the world, and the entry point was a routine npm dependency install.

On May 11, 2026, threat group TeamPCP executed the fourth wave of its Shai-Hulud worm campaign, now tracked as Mini Shai-Hulud. The attack compromised 84 malicious package versions across 42 TanStack packages in the npm registry in a six-minute window, eventually expanding to more than 170 packages across npm and PyPI (Python Package Index) source code registries, including namespaces belonging to Mistral AI, UiPath, and OpenSearch. At least one affected package, @tanstack/react-router, receives approximately 12 million weekly downloads.

This is the fourth wave in an escalating campaign. Prior waves include the initial npm compromise (Shai-Hulud 1.0) and the 2.0 wave targeting GitHub credentials.

OpenAI disclosed this week that two employee devices were compromised. No user data, production systems, or IP were impacted, but containment required isolating systems, rotating credentials, engaging external forensics, and a full rotation of code-signing certificates across macOS, Windows, iOS, and Android triggered by a single dependency install.

Mini Shai-Hulud Wave Four: Quick Facts

  • Attack date: May 11, 2026
  • Packages compromised: 84 malicious versions across 42 @tanstack/* packages; 170+ total across npm and PyPI registries
  • CVE: CVE-2026-45321, CVSS score 9.6 (Critical)
  • Attribution: TeamPCP (also tracked as PCPcat, UNC6780)
  • Mechanism: Three chained GitHub Actions vulnerabilities - Pwn Request, cache poisoning, OIDC (OpenID Connect) token extraction from runner process memory
  • Notable victim: OpenAI - two employee devices compromised; exposed secrets including code-signing certificates for macOS, iOS, Windows, and Android exfiltrated from internal source code repositories
  • Prior waves: Shai-Hulud 1.0 (September 2025), 2.0 (November 2025), and 3.0 (December 2025)
  • Impact: Compromised dev and CI/CD environments, maintainer accounts and packages taken over, and SLSA provenance and signed builds no longer “safe by default”
  • Key risks: Malicious packages that pass SLSA (Supply-chain Levels for Software Artifacts) Build Level three provenance attestation

How the Attack Worked

Mini Shai-Hulud Wave Four is the most technically sophisticated iteration of this campaign to date. Where prior waves relied on compromised maintainer accounts to publish malicious packages directly, Wave Four chained three GitHub Actions vulnerabilities to hijack the legitimate release pipeline itself.

The attack sequence:

  1. Fork and disguise: The attacker forked the TanStack/router repository, renaming it to zblgg/configuration so it wouldn’t show up as an obvious fork in Gitub’s fork list views.
  2. Trigger the workflow: A pull request was opened that triggered a pull_request_target workflow - the "Pwn Request" pattern that grants workflow access to forked code
  3. Poison the cache: The attacker's fork code wrote a poisoned 1.1 GB pnpm-store entry into the GitHub Actions cache, keyed so the release workflow would later restore it
  4. Hide the tracks: The malicious pull request was then force-pushed to a no-operation state and closed to obscure evidence of the compromise
  5. Wait for the trigger: When legitimate TanStack maintainers merged unrelated pull requests to main, the release workflow triggered and restored the poisoned cache
  6. Steal the token: Attacker-controlled binaries read /proc/<pid>/mem of the Runner.Worker process to extract the OIDC token minted for npm trusted publishing
  7. Publish through the pipeline: Those tokens were used to publish 84 malicious package versions to the npm registry through TanStack's own legitimate release pipeline.
  8. The result: packages carrying valid SLSA Build Level three provenance attestations, valid Sigstore attestations, and legitimate GitHub Actions signatures, produced by the legitimate release pipeline, containing credential-stealing malware. As TanStack confirmed in their postmortem, from a developer's perspective the packages appeared cryptographically authentic, with no visible indication of compromise.

Secrets Were Exposed: The malware payload exfiltrated exposed secrets - credentials and tokens that were actively accessible on the compromised systems - via three redundant channels: a typosquat domain (git-tanstack[.]com), the decentralized Session messenger network, and GitHub API dead drops using stolen tokens. Targeted credentials included GitHub tokens, cloud secrets from AWS, GCP, and Azure, CI/CD authentication material, Kubernetes credentials, HashiCorp Vault tokens, and SSH keys.

On developer machines, the malware installed a persistent gh-token-monitor daemon (via macOS LaunchAgent or Linux systemd) that polled GitHub every 60 seconds. On receiving a 40X error from token revocation, the daemon attempted to run rm -rf ~/ wiping the user's home directory. The daemon exited automatically after 24 hours.

OpenAI’s Impact and What It Tells Us

OpenAI's disclosure is precise about what was exfiltrated: limited credential material from a subset of internal source code repositories accessible to the two compromised employees, including code-signing certificates for macOS, iOS, Windows, and Android products. OpenAI confirmed no evidence those certificates were used to sign malicious software, but is rotating all of them precautionarily and requiring macOS users to update their applications before June 12, 2026, after which apps signed with the old certificates may stop functioning.

There is a second detail in OpenAI's disclosure that deserves attention. The two compromised devices had not yet received updated package management configurations, including controls like minimum release age checks and package provenance validation, that were being rolled out across the organization's environment. The attack landed during that rollout window.

This describes a real and common gap. Security controls are deployed incrementally. During any phased rollout, a subset of systems carries greater exposure. TeamPCP's campaign ran continuously across weeks, publishing malicious packages into registries and waiting for them to be installed. The timing was not coincidental.

Verify Your Software Components to Prevent Supply Chain Attacks

MetaDefender Software Supply Chain™ solution is designed to help organizations inspect actual artifacts, packages, and binaries entering the SDLC (Software Development Lifecycle), including packages that carry valid signatures or provenance attestations, providing software visibility across the pipeline at the point packages are consumed.

Three capabilities within MetaDefender Software Supply Chain solution directly address the gaps this attack exploited:

Metascan™ Multiscanning
: combines more than 30 commercial anti-malware engines to scan packages from source code registries including npm and PyPI before they reach developer workstations or CI/CD pipelines. Where a single detection engine may not flag a newly published variant, the combined detection surface reduces the window during which a malicious package can execute without detection.

SBOM (Software Bill of Materials) generation: provides visibility into software components across a stack, direct and transitive dependencies, version history, and registry metadata, with support for more than ten programming languages. SBOM helps make unexpected package changes visible before they propagate downstream, and exports in CycloneDX and SPDX formats to support compliance with regulatory requirements including DORA (Digital Operational Resilience Act).

Proactive DLP™: scans source code for hardcoded secrets - passwords, API keys, tokens, and credentials embedded in code before they have been exposed to attackers. This is distinct from credential exfiltration response: Proactive DLP™ technology addresses the risk that secrets left inside source code or configuration files become accessible when a repository is compromised, as occurred in the OpenAI incident.

MetaDefender Software Supply Chain integrates natively with GitHub, GitLab, Azure DevOps, and Nexus, placing inspection inside the pipeline rather than alongside it. A recent release, version 3.3.0, adds support for secure artifact transfer across isolated environments via one-way data transfer using data diode technology, allowing organizations in air-gapped or high-security environments to validate artifacts before they cross network boundaries, with an available activation process that fits into existing DevSecOps workflows.

Key Takeaways

Provenance attestation indicates origin, not integrity
Wave Four produced validly attested malicious packages because the release pipeline itself was compromised. Signature and provenance checks are a useful signal, not a guarantee of safe content.

The deployment window is an exposure window
OpenAI's incident occurred during a phased rollout of new supply chain controls. Every organization has analogous gaps during control deployment. Content-level inspection at each stage helps reduce dependence on policy coverage being complete before an attack arrives.

This campaign is ongoing
Mini Shai-Hulud is the fourth wave of a campaign that has systematically escalated in technical sophistication since September 2025. Treating any individual incident as resolved without addressing underlying pipeline vulnerabilities leaves organizations exposed to the next iteration.

Combining SBOM visibility, malware multiscanning, and hardcoded secrets detection helps reduce the exposure surface across modern software development environments. Trust no file. Trust no device.

Ready to secure your software development pipeline against supply chain attacks like Mini Shai-Hulud?

Further Readings

Stay Up-to-Date With OPSWAT!

Sign up today to receive the latest company updates, stories, event info, and more.