@poucode/baileys@2.0.4
Malicious code in @poucode/baileys (npm)
Analysis
@poucode/baileys is a fork of the Baileys WhatsApp Web socket library that covertly manipulates the installing user's WhatsApp account and message metadata in favour of the package author. lib/Socket/newsletter.js hardcodes two newsletter JIDs ("120363429394939370@newsletter" and "120363430414713911@newsletter") and, 150 seconds after the socket module is loaded, issues a newsletter FOLLOW mutation (query id 7871414976211147) for each, 5 seconds apart, with no call from the host application and no way for the application to opt out; the effect is that any account running the library is silently subscribed to the author's channels. lib/Socket/luxu.js and lib/Utils/messages.js additionally force author branding onto outgoing traffic: messages built by the library carry a hardcoded forwardedNewsletterMessageInfo with newsletterJid "120363421563597486@newsletter" and newsletterName "PouCode", presented as if the message originated from that channel, and the poll/newsletter helper defaults to JID "120363399602691477@newsletter". On import, lib/index.js prints an author Telegram promotion pointing to hxxps://t[.]me/pouchinfo. The package's preinstall script is only a Node.js >=20 version guard. Network destinations in the shipped code are otherwise official WhatsApp hosts (web[.]whatsapp[.]com, graph[.]whatsapp[.]com, acs[.]whatsapp[.]com, wamo[.]whatsapp[.]net); no credential or environment-variable exfiltration to a third-party host was observed.
- analyzed by
- Leitwacht
- first seen
- Nov 17, 2026, 04:17 AM
- analyzed
- Nov 17, 2026, 04:18 AM
- weekly installs
- 1,104
hxxps://github[.]com/pou-code/WaBail Request takedown / dispute →Related advisories
- @poucode/baileys@2.0.1 same package
- @poucode/baileys@2.0.0 same package
- @poucode/baileys@1.0.2 same package
- @vinzzofficial/baileys@1.0.0
- @bobfrankston/mailx-store-web@0.1.137
- vite-plugin-bar-plus@1.0.47
- @nakanoo/baileys@1.0.0
- @kropaku/baileys@6.7.22
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.