Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

Shai-Hulud v2 Campaign Spreads From npm to Maven, Exposing Thousands of Secrets

0
Medium
Vulnerability
Published: Wed Nov 26 2025 (11/26/2025, 18:08:00 UTC)
Source: The Hacker News

Description

The second wave of the Shai-Hulud supply chain attack has spilled over to the Maven ecosystem after compromising more than 830 packages in the npm registry. The Socket Research Team said it identified a Maven Central package named org.mvnpm:posthog-node:4.18.1 that embeds the same two components associated with Sha1-Hulud: the "setup_bun.js" loader and the main payload "bun_environment.js." "

AI-Powered Analysis

AILast updated: 11/26/2025, 18:10:33 UTC

Technical Analysis

The Shai-Hulud v2 campaign represents a highly impactful supply chain attack targeting open-source package ecosystems, initially npm and now extending into Maven Central. The attack began by compromising over 830 npm packages, embedding malicious JavaScript components named "setup_bun.js" and "bun_environment.js" that act as loaders and payloads respectively. These components backdoor developer environments by injecting rogue GitHub Actions workflows that register victim machines as self-hosted runners, enabling arbitrary command execution triggered by GitHub Discussions. The malware systematically scans infected machines for sensitive secrets such as API keys, cloud credentials (AWS, Google Cloud, Azure), npm and GitHub tokens, and exfiltrates them to randomly named public GitHub repositories to evade detection. The campaign leverages a critical CI/CD misconfiguration involving the risky pull_request_target trigger, allowing execution of attacker-supplied code during continuous integration runs. The Maven compromise occurred via an automated process (mvnpm) that rebundles npm packages as Maven artifacts, unintentionally propagating the infection into the Java ecosystem. The attack has affected over 28,000 repositories and leaked thousands of valid secrets, with over 5,000 files containing exfiltrated data uploaded publicly. The malware uses the Bun runtime environment to conceal its core logic, enhancing stealth and increasing infection scale by raising the infection cap from 20 to 100 packages. This worm-like propagation mechanism allows a single compromised maintainer account to rapidly amplify the attack’s blast radius. The campaign is a continuation of prior ecosystem attacks such as the August 2025 S1ngularity campaign and demonstrates evolving attacker sophistication in supply chain compromise. The incident underscores systemic weaknesses in open-source package publishing, CI/CD pipeline security, and secret management practices, emphasizing the need for improved software supply chain defenses.

Potential Impact

European organizations that develop or consume software relying on npm and Maven packages are at high risk of exposure to this threat. The theft of API keys, cloud credentials, and tokens can lead to unauthorized access to critical cloud infrastructure, data breaches, and lateral movement within corporate networks. Organizations using CI/CD pipelines with GitHub Actions are particularly vulnerable due to the exploitation of workflow misconfigurations, potentially allowing attackers to execute arbitrary code within trusted build environments. The widespread nature of the infection means that many downstream applications and services could be compromised, leading to cascading impacts on software integrity and availability. The exposure of secrets can facilitate further attacks such as ransomware, data exfiltration, and service disruption. Additionally, the stealth and worm-like propagation of the malware increase the difficulty of detection and containment, potentially prolonging exposure and increasing remediation costs. The incident also risks damaging trust in open-source ecosystems widely used across Europe’s technology sectors, including finance, manufacturing, and government services, which rely heavily on these package managers and cloud services.

Mitigation Recommendations

European organizations should immediately rotate all potentially exposed secrets including API keys, cloud credentials, and tokens associated with npm, Maven, and GitHub accounts. Conduct comprehensive audits of all dependencies to identify and remove compromised package versions, replacing them with verified clean versions. Harden CI/CD pipelines by reviewing and correcting GitHub Actions workflows to avoid risky triggers such as pull_request_target and workflow_run that allow untrusted code execution. Implement strict least-privilege access controls on CI/CD environments and repositories to limit the impact of compromised accounts. Deploy automated secret scanning tools integrated into development workflows and enforce policies to prevent secret leakage. Monitor for unusual GitHub repository activity, especially the creation of public repositories with random names that could be exfiltration targets. Collaborate with package registries and security teams to ensure compromised packages are purged and blocked from rebundling. Educate developers on supply chain risks and secure coding practices. Consider adopting software supply chain security frameworks such as Sigstore for package signing and verification to enhance trustworthiness of dependencies.

Need more detailed analysis?Get Pro

Technical Details

Article Source
{"url":"https://thehackernews.com/2025/11/shai-hulud-v2-campaign-spreads-from-npm.html","fetched":true,"fetchedAt":"2025-11-26T18:10:08.616Z","wordCount":1464}

Threat ID: 692742820de433ec09574d35

Added to database: 11/26/2025, 6:10:10 PM

Last enriched: 11/26/2025, 6:10:33 PM

Last updated: 11/26/2025, 9:34:32 PM

Views: 14

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need enhanced features?

Contact root@offseq.com for Pro access with improved analysis and higher rate limits.

Latest Threats