惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

博客园_首页
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Microsoft Azure Blog
Microsoft Azure Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
Recent Announcements
Recent Announcements
L
Lohrmann on Cybersecurity
Vercel News
Vercel News
P
Palo Alto Networks Blog
P
Proofpoint News Feed
WordPress大学
WordPress大学
Know Your Adversary
Know Your Adversary
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
K
Kaspersky official blog
T
Threat Research - Cisco Blogs
GbyAI
GbyAI
L
LangChain Blog
Y
Y Combinator Blog
T
Tenable Blog
腾讯CDC
T
Tailwind CSS Blog
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
NISL@THU
NISL@THU
A
Arctic Wolf
Security Latest
Security Latest
IT之家
IT之家
Latest news
Latest news
Cisco Talos Blog
Cisco Talos Blog
P
Privacy & Cybersecurity Law Blog
T
Tor Project blog
T
Threatpost
Simon Willison's Weblog
Simon Willison's Weblog
Last Week in AI
Last Week in AI
D
Darknet – Hacking Tools, Hacker News & Cyber Security
让小产品的独立变现更简单 - ezindie.com
让小产品的独立变现更简单 - ezindie.com
AWS News Blog
AWS News Blog
月光博客
月光博客
aimingoo的专栏
aimingoo的专栏
量子位
T
Troy Hunt's Blog
Blog — PlanetScale
Blog — PlanetScale
V
Vulnerabilities – Threatpost
I
InfoQ
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
C
Cyber Attacks, Cyber Crime and Cyber Security
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
I
Intezer
爱范儿
爱范儿
C
Cisco Blogs
cs.CV updates on arXiv.org
cs.CV updates on arXiv.org

2024 Sonatype Blog

Open Source, Open Infrastructure, and the Space Between Request for Comments: CARE and Maven Central Q2 2026 Open Source Malware Index AI Is Forcing a New Open Source Security Model Vulnerability Prioritization Is Missing the AI-Era Point The Hidden National Security Threat Inside AI-Driven Software Miasma Returns: Leo Platform Compromise in npm The Rise of Collective Defense for Open Source Signal Over Noise: Reachability Analysis Is the Reality Check SCA Has Been Missing Software Security Has to Start at Assembly easy-day-js Targets Mastra, Dependency Attacks Grow Open Publishing, Commercial Scale Software Dependency Cooldowns Are a Symptom, Not a Strategy Atomic Arch npm Campaign Adds Malicious Dependency From SBOMs to AI BOMs: Why SPDX 3.0 Matters Mythos Found 10,000 Vulnerabilities. The Bigger Challenge Is Fixing Them Lazarus Group's Latest: Brandjacking Campaign on npm 5 Steps to Turn Your RMF Backlog Into a Continuous ATO: The CSRMC Migration Playbook The AI Race Is Becoming a Remediation Race Red Hat Cloud Services npm Packages Hijacked Inside a 176-Package npm Campaign Built to Beat Your Internal Dependencies AI Is Making Software Autonomous, and Governance Must Follow Your Outdated Repository Still Works, But It May Not Be Safe Hijacked npm Package Attempts to Deliver PolinRider-Linked RAT AppSec Tools Explained: SAST vs SCA vs DAST | Sonatype Managing Open Source Software Risks With the HeroDevs EOL Dashboard Shai-Hulud is Back: Maintainer Accounts Are Still the Soft Target Building Trusted AI Development With Kiro and Sonatype Guide How to Build a Software Supply Chain Security Playbook The Evolution of Open Source Malware: From Volume to Trust Abuse The Mythos AI Vulnerability Storm: What to Do Next Malicious PyTorch Lightning Packages Found on PyPI Why Developer Experience Is the Foundation of DevSecOps Success Open is Not Costless: Reclaiming Sustainable Infrastructure Q1 Updates in Nexus Repository: More Formats, Stronger Operations, and a Better Day-to-Day Experience Self-Propagating npm Malware Turns Trusted Packages Into Attack Paths The Time Is Now to Prepare for CRA Enforcement Sonatype Innovate: Real Peer Connections, Real Product Influence, Real Recognition Mythos and the AI Vulnerability Storm: Exploring the Control Point When AI Writes Code, Who Governs the Dependencies? Why Software Supply Chain Security Requires a New Playbook Q1 2026 Open Source Malware Index: Adaptive Attacks Exploit Trust Modernizing Nexus Repository: Moving Beyond OrientDB AI, DevSecOps, and the Future of Application Security: The Gartner® Report How Sonatype's Container Scanning Protects You From Zero-Days Axios Compromise on npm Introduces Hidden Malicious Package Is Your Repository Ready for What's Next? Autonomous Development and AI: Speed vs. Security Grounded Intelligence Ensures Safe AI Software Development Compromised litellm PyPI Package Delivers Multi-Stage Credential Stealer Golden Pull Requests: Automating Trusted Remediation Without Breaking Builds Sonatype Discovers Two Malicious npm Packages
New Shai-Hulud Miasma Wave Hits Hundreds of npm Packages
Sonatype Security Research Team · 2026-06-04 · via 2024 Sonatype Blog

Update, June 5, 2026: As of this date, we have identified a total of 304 components impacted by this malware, expanding on the amount noted in our initial reporting. We will continue to monitor the situation, and we remind users to consult our Sonatype Guide page. Our original blog post continues below.


TL;DR

  • Sonatype Security Research is tracking a new Shai-Hulud Miasma wave with 281 malicious npm package versions that move beyond obvious preinstall and postinstall scripts in package.json.

  • This variant abuses binding.gyp to trigger execution through node-gyp during npm install and can collect developer and CI/CD data, steals credentials, validates access, and self-propagate.

  • Organizations that installed affected versions should treat impacted environments as potentially compromised, rotate credentials, verify package artifacts, and investigate follow-on activity.

Shai-Hulud has re-emerged in a campaign with 281 malicious package versions across the npm ecosystem. This latest wave is part of the campaign dubbed "Miasma: The Spreading Blight" and abuses trust in open source packages to spread through software supply chains.

What makes this wave notable is the change in execution method. Instead of relying only on obvious preinstall or postinstall scripts in package.json, this variant abuses binding.gyp, a file normally used by packages with native Node.js add-ons. The campaign collects data and credentials before, if permissions allow, publishing new malicious versions of legitimate packages.

Organizations that installed affected versions should treat impacted environments as potentially compromised. Removing the package is recommended, but may not be enough if credentials were exposed or follow-on activity occurred.

We are tracking this campaign through Sonatype Guide under sonatype-2026-003581.

What Happened

The Shai-Hulud campaign has resurfaced with a new Miasma wave affecting npm packages modified to include malicious install-time behavior.

Once executed, the malware is designed to:

  • Collect system, user, developer configuration, and CI/CD environment data.

  • Search for GitHub access tokens, package registry authentication tokens, and cloud-related secrets.

  • Validate stolen credentials and enumerate accessible repositories, services, and permission levels.

  • Use stolen maintainer credentials to create and publish malicious package artifacts.

That publishing capability allows attackers to push new malicious versions of legitimate packages and further propagate through compromised repositories, CI/CD environments, and package registries.

This is not just credential theft. It is a self-spreading supply chain attack that uses trusted development relationships as its propagation path.

Why binding.gyp Changes Detection

Most npm malware guidance has trained developers and security teams to look for suspicious lifecycle scripts such as preinstall, install, or postinstall in package.json.

That is still important, but this campaign demonstrates why it is no longer enough.

In the observed Miasma variant, malicious packages can include a small binding.gyp file that causes node-gyp rebuild to run during installation. node-gyp is a legitimate build tool used for compiling native Node.js add-ons, which means its presence may not immediately appear suspicious in isolation.

The malicious behavior comes from abusing command execution inside the binding.gyp configuration. Instead of compiling a legitimate native extension, the configuration can execute a malicious JavaScript payload during the package installation process.

The result is a quieter execution path:

  1. A developer or CI job installs what appears to be a legitimate npm package version.

  2. npm detects binding.gyp and invokes node-gyp rebuild.

  3. The malicious binding.gyp executes the payload.

  4. The payload runs before the application ever imports the package.

  5. Security tools that only inspect package.json lifecycle scripts may miss the behavior.

This is the central lesson of the campaign: install-time risk is broader than install scripts.

A package can look clean at the metadata level and still execute code during installation.

Trusted Packages Are the Delivery Mechanism

This campaign reinforces a critical point: attackers do not need to convince developers to install obviously suspicious packages if they can compromise packages developers already trust.

Modern software teams rely heavily on reputation signals: a familiar package name, a legitimate maintainer, a known namespace, historical downloads, or prior approval in an internal catalog. Those signals are useful, but they are not sufficient.

A package can be safe on Monday and compromised on Tuesday. A maintainer account can be trustworthy until its token is stolen. A package version can come from a legitimate registry and still contain malicious code.

That is the attacker's advantage: assumed trust. Software teams are making more trust decisions faster than humans can realistically govern manually. Developers are accepting generated code, adding dependencies, updating packages, and shipping through automated pipelines at a pace that exceeds traditional review models.

That speed is not the problem. Ungoverned trust is.

How to Determine If You Are Affected

Organizations should investigate whether affected package versions were installed in developer environments, CI/CD pipelines, build containers, or production-adjacent systems.

Start by reviewing:

  • Dependencies and lockfiles: Search for affected packages in package.json, package-lock.json, yarn.lock, pnpm-lock.yaml, build manifests, and container images. Lockfiles and package caches may provide the best evidence if malicious versions were only available for a limited window.

  • CI/CD logs: Look for suspicious install-time behavior, including unexpected node-gyp rebuild activity, large or obfuscated JavaScript files, Bun downloads during dependency installation, or outbound connections that do not align with a normal package install.

  • Repository configuration: Inspect for unexpected AI assistant or IDE configuration changes, including files related to Claude Code, Cursor, Gemini, VS Code, and GitHub workflows.

Because the malware targets credentials, any confirmed installation should be treated as a potential compromise of the environment in which it ran.

Assume Compromise If Malicious Versions Were Downloaded

If your organization installed an affected version, assume the environment may be compromised and begin credential rotation immediately.

Prioritize npm tokens, GitHub tokens, GitHub Actions credentials, cloud provider credentials, package registry credentials, SSH keys, and any secrets available to the affected developer machine or CI/CD runner. Review GitHub, npm, and cloud audit logs for unexpected repository access, package publishes, workflow changes, token use, or newly created repositories.

Next, remove affected package versions and ensure applications and build processes use uncompromised versions. Because this attack involves compromised versions of legitimate packages, simply approving the package name is not enough. Teams must verify the exact version and artifact.

Security teams should also audit repositories for unexpected commits or configuration files, especially under directories including:

  • .github/

  • .claude/

  • .cursor/

  • .gemini/

  • .vscode/

Where suspicious changes are found, remove them and review commit history for unauthorized activity.

Finally, investigate whether any package publishing credentials were exposed. If an attacker obtained maintainer-level access, the response must include downstream package integrity review, not just local cleanup.

Cooldown Periods Are a Temporary Fix

One practical defense against fast-moving npm compromises is a cooldown period for newly published package versions. Holding new versions for review or allowing time for malicious packages to be identified can reduce exposure to attacks that are discovered shortly after publication.

Cooldown periods and other time-based remedies help to a point. But they are not a complete defense against campaigns that compromise trusted open source projects and use legitimate package workflows to spread.

The deeper issue is structural. Organizations need continuous visibility into open source behavior, package integrity, maintainer risk, and install-time activity. They need to evaluate not just whether a package was approved in the past, but whether the specific version being introduced today shows signs of malicious activity.

That means security programs must continuously audit open source software as it enters development and build environments. They must also account for AI-assisted development workflows, where coding assistants can recommend dependencies, generate package installation commands, or interact with repository configuration.

Governance Must Be Automated

The next wave of supply chain attacks will not wait for quarterly policy reviews.

Trusted open source projects are being taken over as part of systemic campaigns. Install-time execution paths are expanding. Credential theft is feeding propagation. AI-era development workflows are creating new places for malicious configuration to hide.

Organizations cannot rely on yesterday's trust decision to protect today's build.

Every new package version is a new risk decision.

Tags

npm security research supply chain attacks malicious code npm Malware Analysis Malware Sonatype Guide