<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>Developer Security - PhishFort | AI-Powered Brand Protection</title><link>https://phishfort.com/resources/blog/tag/developer-security/</link><description>PhishFort delivers agentic brand protection: detecting and eliminating phishing sites, fake apps, and impersonations across every digital channel.</description><generator>Hugo -- gohugo.io</generator><language>en-US</language><lastBuildDate>Thu, 03 Sep 2026 12:00:00 +0000</lastBuildDate><atom:link href="https://phishfort.com/resources/blog/tag/developer-security/index.xml" rel="self" type="application/rss+xml"/><item><title>Shai-Hulud Returns: The npm Supply Chain Worm Turning Stolen Credentials Into New Infections</title><link>https://phishfort.com/shai-hulud-npm-supply-chain-worm/</link><pubDate>Sun, 02 Aug 2026 13:00:00 +0000</pubDate><dc:creator>PhishFort Team</dc:creator><guid>https://phishfort.com/shai-hulud-npm-supply-chain-worm/</guid><description><![CDATA[<p>A new npm supply-chain attack is actively spreading through the JavaScript ecosystem, turning stolen developer credentials into a mechanism for further infection.</p>
<p>The campaign, identified on August 4, 2026, began with the compromise of a GitHub account belonging to the maintainer of <code>keyv</code>, a key-value storage library with roughly 127 million weekly downloads. From there, attackers published malicious package versions containing a credential-harvesting payload, along with a self-propagating worm that uses stolen credentials to infect packages maintained by completely unrelated organizations.</p>]]></description><content:encoded><![CDATA[<p>A new npm supply-chain attack is actively spreading through the JavaScript ecosystem, turning stolen developer credentials into a mechanism for further infection.</p>
<p>The campaign, identified on August 4, 2026, began with the compromise of a GitHub account belonging to the maintainer of <code>keyv</code>, a key-value storage library with roughly 127 million weekly downloads. From there, attackers published malicious package versions containing a credential-harvesting payload, along with a self-propagating worm that uses stolen credentials to infect packages maintained by completely unrelated organizations.</p>
<p>By August 5, researchers had identified at least 444 compromised packages across 1,381 versions, representing more than 2 billion monthly installs. The campaign has continued to evolve.</p>
<p>The attack is tracked as a new iteration of Shai-Hulud, a supply-chain malware family previously associated with large-scale npm compromises. This time, the malware isn&rsquo;t simply stealing secrets. It&rsquo;s using those secrets to spread.</p>
<p>For background on how supply chain attacks of this type target developers, see our overview of <a href="/open-source-supply-chain-attack-developer-targets/" target="_blank" rel="noopener">open-source supply chain attacks targeting developers.</a> For the trusted-software variant, see <a href="/uac-0099-notepad-winrar-plugin-hijacking/" target="_blank" rel="noopener">how UAC-0099 weaponized Notepad++ and WinRAR plugins</a>. For a broader roundup of recent incidents, see our <a href="/supply-chain-attack-news/" target="_blank" rel="noopener">supply chain attack news coverage</a>. The Shai-Hulud campaign is a documented real-world example of exactly what that coverage describes: a single maintainer account compromise that became an ecosystem-wide worm.</p>
<h2 id="what-happened">What Happened</h2>
<p>The initial compromise targeted the GitHub account of the <code>keyv</code> maintainer. The attacker gained control of that account and used it to modify the package source and publish a malicious release.</p>
<p>The first confirmed malicious release was <code>keyv@6.0.0</code>, along with a set of dependent packages: <code>flat-cache</code>, <code>file-entry-cache</code>, <code>cacheable-request</code>, <code>cacheable</code>, <code>@cacheable/memory</code>, <code>cache-manager</code>, <code>@cacheable/node-cache</code>, <code>@cacheable/utils</code>, and <code>@cacheable/net</code>.</p>
<p>These packages sit deep inside dependency trees, so organizations don&rsquo;t need to have explicitly installed <code>keyv</code> to be exposed. Socket identified dependency chains in which widely used tools like ESLint indirectly depend on packages within the compromised ecosystem.</p>
<p>This is one of the defining characteristics of supply-chain attacks: the victim doesn&rsquo;t need to trust the attacker. They only need to trust their dependencies.</p>
<h2 id="how-the-malicious-package-stays-hidden">How the Malicious Package Stays Hidden</h2>
<p>One of the most concerning aspects of this attack is how little the malicious release changes on the surface.</p>
<p>In <code>keyv@6.0.0</code>, researchers found that the package&rsquo;s normal <code>dist/</code> output was byte-for-byte identical to the clean release. The malicious functionality was instead introduced through <code>package.json</code> and additional files, specifically a lifecycle hook:</p>
<pre tabindex="0"><code>preinstall: node setup.mjs
</code></pre><p>This means the malicious code executes automatically when the affected package is installed, before any application code runs. The <code>setup.mjs</code> loader then downloads a standalone Bun runtime and uses it to execute a second-stage payload. The package can behave exactly like the legitimate library while the installation process compromises the machine. That makes application-level code review significantly less effective as a sole control.</p>
<h2 id="what-the-malware-collects">What the Malware Collects</h2>
<p>The payload searches aggressively for credentials and secrets across the developer environment, targeting: npm authentication tokens, GitHub personal access tokens, GitHub App tokens, GitHub Actions OIDC credentials, AWS credentials and Secrets Manager access, Kubernetes service-account tokens and configuration, HashiCorp Vault and Terraform credentials, SSH keys and certificates, Docker registry credentials, Stripe API keys, Slack tokens, <code>.env</code> files, CI/CD credentials, and cryptocurrency-related keystores.</p>
<p>Wiz&rsquo;s analysis notes that the latest version has significantly expanded its capabilities, now including credentials associated with AI development tools including Claude, OpenAI, Codex, Cursor, and Gemini, as well as additional CI/CD, cloud, and cryptocurrency infrastructure, becoming a true developer-environment credential harvesting framework.</p>
<h2 id="from-credential-theft-to-self-propagation">From Credential Theft to Self-Propagation</h2>
<p>The most important element of this campaign is what happens after credentials are stolen: the malware uses compromised npm credentials to identify packages the victim is authorized to publish, then injects malicious lifecycle hooks into those packages and publishes new, infected versions back to the npm registry. The newly infected package can then compromise another developer, who may have access to completely different packages, who can infect additional developers.</p>
<p>The result is a self-propagating supply-chain worm. This is why the scope expanded so quickly beyond the original <code>keyv</code> and <code>cacheable</code> namespaces. The first compromised maintainer was merely the first link in a chain of package compromises.</p>
<h2 id="github-as-a-second-propagation-layer">GitHub as a Second Propagation Layer</h2>
<p>But the attack doesn&rsquo;t stop at npm. The malware uses stolen GitHub credentials to modify repositories, with malicious hooks inserted into <code>.claude/settings.json</code> and <code>.vscode/tasks.json</code> in some cases. This means a developer could trigger malicious behavior merely by cloning an infected repository and opening it in their development environment, without even having to run <code>npm install</code> themselves.</p>
<p>The attack therefore targets multiple layers of the modern developer workflow: npm package installation, developer workstations, GitHub repositories, CI/CD runners, cloud credentials, and further npm packages. That dramatically increases the potential blast radius.</p>
<h2 id="provenance-checks-arent-enough">Provenance Checks Aren&rsquo;t Enough</h2>
<p>Perhaps the most uncomfortable lesson from this incident is that the compromised packages could still appear legitimate from a software provenance perspective. The attacker controlled the maintainer&rsquo;s GitHub account and used the legitimate release workflow, so poisoned releases could carry valid provenance from the legitimate GitHub Actions build process.</p>
<p>A package can be correctly signed, correctly built, published through a legitimate CI pipeline, associated with the expected maintainer identity, and still be malicious.</p>
<p>Provenance tells you where software came from, but it can&rsquo;t guarantee that the source it hasn&rsquo;t itself been compromised.</p>
<h2 id="resilient-infrastructure">Resilient Infrastructure</h2>
<p>Stolen credentials are encrypted before exfiltration and can be uploaded to public GitHub repositories under compromised identities. Researchers identified repositories using the description &ldquo;Shai-Hulud: Here We Go Again.&rdquo;</p>
<p>More notably, the malware retrieves command-and-control infrastructure through an Ethereum smart contract, meaning the attacker can update parts of the infrastructure without publishing a new payload, making disruption harder.</p>
<h2 id="what-security-teams-should-do-now">What Security Teams Should Do Now</h2>
<p>Organizations using npm should treat this as an active incident.</p>
<p><strong>Identify affected packages and versions.</strong> Review dependency manifests and lock files across developer workstations, production applications, build systems, CI/CD runners, containers, and internal registries. Don&rsquo;t limit the review to direct dependencies: examine the complete dependency tree.</p>
<p><strong>Remove compromised versions.</strong> Affected versions should be removed and replaced with known-good releases. Upgrading alone is not sufficient if the malicious version already executed.</p>
<p><strong>Assume credentials may be exposed.</strong> If an affected package ran in any environment containing credentials, treat those credentials as potentially compromised. Prioritize rotation of npm tokens, GitHub tokens, AWS credentials, cloud API keys, SSH keys, Kubernetes credentials, Vault tokens, Terraform credentials, and CI/CD secrets. Wiz specifically recommends treating systems that installed affected packages as potentially compromised and rebuilding where appropriate.</p>
<p><strong>Investigate GitHub activity.</strong> Look for unexpected commits, force pushes, new repositories, unexpected package releases, suspicious GitHub Actions activity, changes to <code>.vscode/tasks.json</code> and <code>.claude/settings.json</code>, and unexpected OAuth applications or tokens.</p>
<p><strong>Review cloud activity.</strong> If the affected package ran on a CI runner or cloud-hosted environment, investigate credentials available to that environment: unusual AWS API calls, new IAM credentials, Secrets Manager access, Kubernetes API activity, and Vault access.</p>
<p><strong>Monitor for campaign indicators.</strong> Known infrastructure includes <code>npm-cache\[.\]com</code>, <code>pypi-get\[.\]com</code>, and <code>js-mirror\[.\]com</code>. Filename indicators include <code>Math_Symbol.js</code>, <code>math_init.js</code>, and <code>setup.mjs</code>. Researchers have published hashes and additional indicators in the sources linked below.</p>
<h2 id="the-bigger-picture">The Bigger Picture</h2>
<p>The Shai-Hulud campaign is a reminder that modern organizations have an enormous external attack surface that doesn&rsquo;t appear in traditional asset inventories.</p>
<p>Your organization may not own the npm registry, GitHub, a dependency&rsquo;s maintainer account, an open-source library, or a third-party CI runner. But your organization may trust all of them. That trust creates an attack path.</p>
<p>Supply chain attackers understand this. Instead of attacking a large enterprise directly, they compromise a maintainer with access to a widely used package. Instead of stealing credentials from thousands of organizations individually, they compromise one developer environment and harvest what&rsquo;s already there. The dependency ecosystem distributes the rest.</p>
<p>The immediate priority is containment: identify affected versions, remove them, assume credentials are exposed, rotate secrets, investigate downstream access, rebuild compromised environments, and monitor for continued propagation.</p>
<p>Supply chain security can&rsquo;t stop at vulnerability scanning. Organizations need visibility into what they trust, who publishes it, how it&rsquo;s built, what executes during installation, and what credentials are available to the environment running it.</p>
<p>At PhishFort, we track campaigns that weaponize trusted infrastructure against developers and brands. <a href="/capabilities/brand-monitoring/" target="_blank" rel="noopener">See how we monitor for supply chain threats and malicious ecosystem activity →</a></p>
<hr>
<p>Sources:</p>
<ul>
<li><a href="https://www.aikido.dev/blog/keyv-and-friends-compromised-in-npm-supply-chain-attack" target="_blank" rel="noopener">Aikido — Keyv and friends compromised in active Shai-Hulud supply chain attack</a>
</li>
<li><a href="https://www.wiz.io/blog/keyv-and-cacheable-npm-supply-chain-attack" target="_blank" rel="noopener">Wiz Research — keyv and cacheable npm Package Hijacked in Supply Chain Attack</a>
</li>
<li><a href="https://socket.dev/blog/popular-npm-packages-in-the-keyv-and-cacheable-namespaces-compromised-in-active-supply-chain" target="_blank" rel="noopener">Socket Research — Popular npm Packages in the keyv and Cacheable Namespaces Compromised in Active Supply Chain Attack</a>
</li>
</ul>
]]></content:encoded><category>Research</category><category>phishing</category><category>security</category><category>Supply Chain Security</category><category>Malware</category><category>Developer Security</category><category>npm</category></item></channel></rss>