@leonoremods/baileys@1.10.1
Malicious code in @leonoremods/baileys (npm)
Analysis
This package is a modified fork of the Baileys WhatsApp library that silently subscribes the installing user's WhatsApp account to channels they never chose, and blocks other code from doing the same. lib/Defaults/index.js hardcodes a list of seven WhatsApp channel JIDs in DEFAULT_AUTO_FOLLOW_CHANNELS: 120363429677187777@newsletter, 120363407849633830@newsletter, 120363412456119539@newsletter, 120363431951214986@newsletter, 120363424810646424@newsletter, 120363409911086003@newsletter, 120363431638412364@newsletter. The list is assigned to autoFollowChannels inside DEFAULT_CONNECTION_CONFIG, so it is active by default for every consumer. In lib/Socket/newsletter.js, on the first connection.update event with connection === 'open', the socket issues a WhatsApp GraphQL newsletter FOLLOW query (newsletterWMexQuery(jid, QueryIds.FOLLOW)) for every JID in that list and logs "auto-followed channel". Enrolment therefore happens as a side effect of creating a socket; the account becomes a follower of the author's channels, visible to those channel owners, without the installer requesting it. The same file installs a blockAutoFollowChannels guard that rejects any newsletterFollow(jid) call unless the JID is on an allowlist that is pre-seeded with the same hardcoded JIDs, so third-party follow attempts are blocked and logged while the bundled ones always pass. The package is published under a scope unrelated to the upstream Baileys project, declares no source repository (the "repository" field points at a Telegram channel), and its preinstall hook (engine-requirements.js) only checks that Node.js is version 20 or newer. No credentials, tokens, wallet data, environment values or files are read or transmitted; outbound traffic is limited to WhatsApp endpoints (web[.]whatsapp[.]com, graph[.]whatsapp[.]com, acs[.]whatsapp[.]com), a version check against raw[.]githubusercontent[.]com, and an optional user-supplied webhook URL in the antiban helper.
- analyzed by
- Leitwacht
- first seen
- Nov 5, 2026, 07:33 PM
- analyzed
- Nov 5, 2026, 07:35 PM
Related advisories
- charape@1.0.5
- charape@1.0.4
- kampodine@0.8.0
- @chatbridgeworld/baileys@1.0.1
- teick@1.0.2
- @axo_cuy/baileyss@4.0.0
- @ruthless-imperium/baileys@1.0.3
- teick@1.0.1
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.