
Recent findings have brought renewed attention to the security threats lurking within the npm ecosystem. An emerging campaign linked to North Korean cyber operations is leveraging malicious npm packages to compromise the computers of software developers, primarily by posing as technology recruiters offering high-paying remote roles. This calculated strategy, combining technical subterfuge and convincing social engineering, highlights just how vulnerable open-source supply chains can be to sophisticated attacks.
Investigators discovered that the orchestrators behind this campaign, believed to be connected to the “Contagious Interview” operation, have published 35 distinct npm packages across 24 accounts. These packages have surpassed 4,000 downloads, and worryingly, several are reportedly still available on the registry. The attack methodology is deeply rooted in social engineering: job-hunting developers are approached, typically via LinkedIn, by individuals presenting themselves as recruiters. The developers are then sent coding assignments through Google Docs or Bitbucket repositories, with these fake assessments containing instructions to install specific npm modules—modules that, in reality, are laced with malware.
Technical Breakdown: Multi-Stage Malware Delivery

Beneath the surface, the attack infrastructure employs a multi-layered deployment strategy engineered for persistence and stealth. The infection chain begins with the HexEval Loader, a loader hidden within the npm package that fingerprints the host system and initiates communication with the attackers’ remote infrastructure. Hex encoded strings and obfuscated code ensure that critical details—like command-and-control endpoints—are only revealed at runtime, making the loader difficult to detect during static analysis.
Once a victim installs the compromised package and runs the provided code, HexEval sends off detailed system information (like OS details, hostname, and network info) and fetches the next stage: BeaverTail. This malware is designed as a cross-platform infostealer, adept at collecting browser data, session tokens, and cryptocurrency wallet files. If the target matches desired criteria, BeaverTail then loads InvisibleFerret, a backdoor that allows attackers to remotely access files, take screenshots, and maintain control of the device long after the initial breach.
Notably, some of the malicious npm packages wield an additional weapon: a keylogger capable of recording keystrokes and exfiltrating sensitive data in real time. Analysts found that this functionality appears to be reserved for especially high-value or tailored victims, as it was only uncovered in a subset of the attacker accounts.
Typosquatting and Impersonation of Trusted Projects
One of the most troubling aspects of the scheme is the use of typosquatted package names, which mimic reputable libraries to increase the likelihood of accidental installations. Examples cited by security researchers include slight variations or misspellings of popular projects, such as react-plaid-sdk, reactbootstraps, vite-plugin-next-refresh, node-orm-mongoose, and chalk-config. Such deceptive tactics are highly effective, as developers moving quickly may inadvertently install a malicious package, believing it to be a well-established library.
The approach is made all the more convincing by the personalized communication from the attackers. Utilizing open-source intelligence, the adversaries craft bespoke outreach to job seekers, offering roles with purported salaries between $192,000 and $300,000 to lure victims into their web. Candidates are often pressured to execute the code “live”—sometimes during screen-shared interviews—and are discouraged from running it within safe, containerized environments.
Security analysts have pointed out that the combination of delayed malware staging, minimal registry footprint, and conditional payload delivery complicates both automated and manual review efforts. This evolution in attacker methodology demonstrates a deep familiarity with how developers work and the security tools they rely upon.
Defensive Steps for Developers and the Open-Source Community
Conscious of the risks associated with the npm registry and open-source supply chain, it is crucial for developers to adopt proactive security measures. It is recommended that unknown packages should always be tested in contained or virtualized environments before any execution on a local machine. Incorporating tools that analyze potential threats in npm packages can significantly reduce the risk of infiltration. Additionally, the adoption of advanced malware detection tools and a heightened awareness of social engineering tactics are also essential steps to reduce exposure.
As attacks like this show no sign of abating, the open-source ecosystem must continue to fortify its defenses. The rapid response from the security research community, including efforts to flag and remove active threats, is instrumental in limiting the reach of such operations. Ongoing diligence and education remain critical for keeping the npm ecosystem secure. Para profundizar en estrategias de protección, consulta nuestro artículo sobre cómo proteger tus proyectos de npm.