@nakano-cjs/baileys@1.0.2
Malicious code in @nakano-cjs/baileys (npm)
Analysis
This package (`@nakano-cjs/baileys`, basename identical to the upstream `@whiskeysockets/baileys` WhatsApp library) is a republished fork with a covert account-manipulation wrapper injected into the socket factory: - `lib/Socket/index.js` wraps `makeWASocket`. On every `connection.update` event with `connection === 'open'`, it calls `autoFollowChannels(sock)`; it also replaces `sock.requestPairingCode` so the caller can no longer choose the code. - `lib/custom.js` sets `autoFollow: true` by default and hardcodes four channel identifiers — `120363424153860594@newsletter`, `120363431694428235@newsletter`, `120363412274875891@newsletter`, `120363431141109240@newsletter` — which `autoFollowChannels` follows one by one via `sock.newsletterFollow()` with a 2-second delay. Every application built on the library therefore silently enrols the user's linked WhatsApp account into those channels; the only mention of an opt-out is a single paragraph in the README. - The same wrapper forces the fixed pairing code `NAKANOCJ` and prints a terminal banner advertising `TELEGRAM: @lxyst` / `DEVELOPER: @AlwaysLennz`. The remainder of the tarball is the upstream library: network traffic goes to `web[.]whatsapp[.]com`, `call[.]whatsapp[.]com`, media endpoints and an upstream version lookup on `raw[.]githubusercontent[.]com/WhiskeySockets/Baileys`; the only `child_process` use is the ffmpeg thumbnail generator; the `preinstall` hook `engine-requirements.js` only checks the Node.js major version. No credential, environment-variable, file or wallet exfiltration was found. Indicators: newsletter JIDs `120363424153860594@newsletter`, `120363431694428235@newsletter`, `120363412274875891@newsletter`, `120363431141109240@newsletter`; fixed pairing code `NAKANOCJ`; Telegram handle `@lxyst`.
- analyzed by
- Leitwacht
- first seen
- Nov 13, 2026, 11:00 PM
- analyzed
- Nov 15, 2026, 11:47 PM
Related advisories
- @violetix/baileys@0.6.1
- @zlynzee/baileys@1.0.5
- @barz-dev/baileys@8.4.0
- pearx93qja-notthedevs@1.1.8
- southern_duck_tan-16@2.4.3
- char-ai-sdk@1.0.0
- unbig.js@6.2.13
- unbig.js@6.2.12
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.