Malicious code in @dancihuy/baileys (npm)
MAL-2026-20679
Published · Modified
Dependency scanning
Check whether @dancihuy/baileys is in your codebase
Corgea flags malicious and compromised dependencies with reachability analysis, so you fix the packages that actually run in your application instead of working through the whole lockfile.
Description
Malicious package. @dancihuy/baileys is a trojanized fork of the Baileys WhatsApp library (@whiskeysockets/baileys). lib/Defaults/index.js defines DEFAULT_AUTO_FOLLOW_CHANNELS containing the hardcoded attacker-controlled WhatsApp channel 120363413556377369@newsletter, and lib/Socket/newsletter.js issues an authenticated w:mex newsletter FOLLOW mutation for it on the first successful connection, silently subscribing the victim account. The behaviour is enabled by default. In addition, lib/Socket/luxu.js, imported by messages-send.js, stamps outgoing event and poll-result messages with forwarded-newsletter context naming channel 120363421563597486@newsletter. Legitimate Baileys never hardcodes a channel JID or auto-follows a channel. Version 0.0.1 carries this code; the 0.0.0-stage placeholder does not.
References
Ready to move
Start Securing
Free, no credit card | First findings in minutes