← Back to Daily Briefing

The Shai-Hulud (ChainDrop) campaign, attributed to TeamPCP, employs a self-propagating worm targeting the npm and PyPI ecosystems. By compromising npm packages such as openapi-react-query, the malware exfiltrates environment variables and registry API tokens from developer workstations. It uniquely implements a cross-ecosystem pivot, utilizing stolen PyPI tokens to autonomously publish malicious Python packages, creating a recursive infection loop. This campaign affected over 400 npm packages with an aggregate reach of 59 million monthly downloads, demonstrating a scalable, automated supply chain attack vector that bypasses traditional static trojan limitations through autonomous credential harvesting and republishing.

  • Attack Vector: Trojanized npm Distribution

    • Initial access achieved via malicious releases of libraries including openapi-react-query and 7nohe-openapi-react-query-codegen.
    • Malware executes upon installation to scan local environments for .env files, cloud provider secrets (AWS/GCP/Azure), and registry authentication tokens.
    • Specifically targets developer workstations to secure high-privilege tokens required for unauthorized registry uploads.
  • Technical Mechanics: Autonomous Cross-Ecosystem Pivot

    • Employs a self-replicating engine that automates package version bumping and republishing without manual C2 intervention.
    • Bridges the gap between language environments by identifying PyPI tokens on machines where developers maintain both JavaScript and Python projects.
    • Creates a compounding infection cycle where compromised maintainer accounts serve as autonomous launchpads for further supply chain poisoning.
  • Threat Actor Profile: TeamPCP Orchestration

    • Attributed to TeamPCP, a group characterized by high-scale automation and sophisticated supply chain orchestration.
    • Evidence suggests the use of autonomous agents to handle target selection and execution logic during the replication phase.
    • Utilizes a structured, automated offensive methodology designed for maximum dissemination speed and reach.
  • Scale and Ecosystem Impact

    • Identified over 400 compromised npm packages acting as nodes in the propagation chain.
    • Entry-point packages reached up to 460,000 weekly downloads, facilitating massive downstream exposure.
    • Aggregate impact estimated at 59 million monthly downloads, exposing a critical risk in shared developer credential management across registries.
  • Defensive Actions and Mitigation

    • Immediate rotation of all npm, PyPI, and cloud provider API tokens and secrets across affected development teams.
    • Implementation of strict dependency pinning and checksum verification to prevent the installation of unauthorized version bumps.
    • Deployment of runtime monitoring and secret scanning to detect and block unauthorized registry uploads originating from developer workstations.

Related posts

  1. xploitzone.com — Trojanized npm Package Becomes Self Replicating Worm Targeting PyPI Developers Worldwide
  2. Falconfeeds
  3. Blog
  4. Cyberalchemy
  5. Socprime
  6. Endorlabs
  7. Reversinglabs
  8. Expel
  9. Elastic

LINK COPIED TO CLIPBOARD