8 min read
|
Saved February 14, 2026
|
Copied!
Do you care about this?
This article details how ten malicious npm packages use typosquatting techniques to execute credential harvesting malware on developers' systems. It describes the multi-stage process, including automatic execution, IP tracking, and extensive data extraction methods targeting various operating systems.
If you do, here's more
The article outlines a serious security threat involving ten typosquatted npm packages that execute a multi-stage credential harvester when developers install them. These malicious packages exploit npm's `postinstall` lifecycle hook to run a script (`install.js`) that detects the victim's operating system and launches an obfuscated payload. This automatic execution poses a significant risk, as developers might unknowingly install these packages while thinking they are legitimate.
The malware employs a sophisticated obfuscation technique, using an XOR cipher with a dynamically generated key based on the decoder function's source code. This makes it difficult to decrypt the payload without running the malicious code. Once installed, the malware sends the victim's IP address to a remote server for tracking and geolocation purposes, ensuring it targets specific profiles. Upon user interaction with a fake CAPTCHA, the malware downloads and executes a binary named `data_extracter`, which is designed to harvest credentials from various storage mechanisms on Windows, macOS, and Linux.
The `data_extracter` binary is a PyInstaller-packaged application, making it portable and difficult to analyze. It scans the file system for sensitive information, including AWS credentials and SSH keys. The threat actor can extract this data and send it back to their command and control server. The extensive functionality of the binary, indicated by over 289,000 embedded strings, highlights its capability to compromise a wide range of credentials. This threat underscores the importance of vigilance when installing packages from npm and the potential risks tied to typosquatting attacks.
Questions about this article
No questions yet.