Intelligence
highSupply ChainActive

Typosquatting Alibaba npm Dependencies: 18 Malicious Packages Distribute Cross-Platform RAT

Attackers published 18 malicious npm packages impersonating Alibaba internal libraries, most notably 'lib-mtop', to distribute a cross-platform remote access trojan to Chinese-speaking developers. This is a targeted supply chain attack exploiting npm's public registry to reach a specific user demographic.

S
Sebastion

Affected

npm registry usersAlibaba tool usersChinese-speaking developer communities

Researchers identified 18 malicious packages on the npm public registry designed to mimic legitimate Alibaba internal libraries. The attack exploits a fundamental trust problem in package managers: developers often depend on private packages without verifying namespace ownership, creating an opportunity for attackers to register unscoped packages with identical names to public registries. 'lib-mtop' appears to be a direct impersonation of an Alibaba private package, suggesting the attacker had knowledge of internal development practices.

The payload is a cross-platform remote access trojan, indicating the attackers developed multi-platform capability rather than targeting a single operating system. This suggests either sophisticated tooling infrastructure or a well-resourced threat actor. The geographically and linguistically targeted nature of the attack (focusing on Chinese-speaking environments and Alibaba tools specifically) indicates the threat actor either has regional focus or conducted reconnaissance on the target community.

The attack succeeds because dependency installation is typically automated and trusted. Developers running 'npm install' on projects with transitive or direct dependencies on these packages would unknowingly execute the RAT during installation or at runtime. The attacker gains arbitrary code execution within the development environment and, if the infected developer builds and distributes their own software, potentially within end-user environments as well.

Defenders should immediately audit npm dependency trees for these 18 packages, remove them, and rotate credentials from any affected development machines. Organisations should implement package allow-listing, namespace verification checks, and consider private npm registries with strict access controls. The npm ecosystem should address this through better namespace collision warnings and mandatory verification for packages claiming to provide popular libraries.

This incident reveals how supply chain attacks can exploit legitimate package manager architecture without requiring a compromise of maintained projects. The targeted nature suggests this was not opportunistic but planned reconnaissance of a specific developer community, raising concerns about whether similar campaigns are targeting other regional or industry-specific tool ecosystems.