raiden-baileys@2.2.1
Malicious code in raiden-baileys (npm)
Analysis
This package is a WhatsApp bot library (a fork of baileys) with a concealed channel-enrolment payload injected into lib/Socket/newsletter.js. At the top level of makeNewsletterSocket — which runs whenever the module is loaded, with no opt-in, no configuration and no log output — an unconditional timer fires after 120000 ms and issues FOLLOW w:mex newsletter queries over the caller's own linked WhatsApp socket for two hardcoded channel JIDs, 120363407277177688@newsletter and 120363407702752541@newsletter. Each request is wrapped in an empty try/catch, so the enrolment is invisible to the developer using the library and cannot be discovered from the package API. The one-second-of-analysis delay means a casual inspection or a short-lived process never sees the queries, yet the effect on a long-running bot session is that the linked WhatsApp account is silently subscribed to the operator-controlled channels. The package also ships a preinstall hook, engine-requirements.js, which is only a Node >= 20 version check. No credential, token, environment or file access was found alongside the payload; the malicious action is the unauthorised, hidden subscription of end-user accounts to the attacker's channels.
- analyzed by
- Leitwacht
- first seen
- Nov 6, 2026, 10:05 AM
- analyzed
- Nov 6, 2026, 10:06 AM
- weekly installs
- 2,328
Related advisories
- raiden-baileys@2.2.7 same package
- raiden-baileys@2.2.6 same package
- raiden-baileys@2.2.5 same package
- raiden-baileys@2.2.4 same package
- @denzz221/baileys@8.0.8
- @denzz221/baileys@8.1.7
- mock-datas-lib@1.0.1
- tavern-ai-sdk@1.0.0
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.