@zervonex/baileys@4.0.9
Malicious code in @zervonex/baileys (npm)
Analysis
This package publishes under the unofficial scope @zervonex while presenting itself as a drop-in replacement for the @whiskeysockets/baileys WhatsApp Web library, and it carries three behaviours an installer would not expect. First, WAProto/fetcher.js downloads wa-version.json and WAProto.bundle.js from the mutable publisher-controlled branch hxxps://raw[.]githubusercontent[.]com/nexustechpro2/baileys/wa-cache; WAProto/index.js then reads the downloaded source and compiles it into the package's WAProto.proto / WAProto.json tables inside the installed package directory. Because that branch is outside npm's integrity guarantee, the protocol handling the library loads can be replaced at any time after publication. Second, lib/Socket/newsletter.js hardcodes AUTO_FOLLOW_JIDS = ['120363422827915475@newsletter','120363409522637051@newsletter'] and lib/Defaults/index.js ships autoFollowNewsletter: true, so on every connection open the connected WhatsApp account is made to follow those two channels, re-attempted on a 30-second interval, and admin notifications for them are switched off; opting out requires setting autoFollowNewsletter: false. Third, package.json declares dependencies on @cacheable/node-cache ^3.1.1 and cache-manager ^7.2.9, which resolve to versions of packages already identified as malicious, and its preinstall hook runs node ./engine-requirements.js. The package performs no local obfuscation: no eval/new Function, no encoded string blobs. IOCs: hxxps://raw.githubusercontent[.]com/nexustechpro2/baileys/wa-cache, files wa-version.json and WAProto.bundle.js; WhatsApp channel JIDs 120363422827915475@newsletter and 120363409522637051@newsletter.
- analyzed by
- Leitwacht
- first seen
- Nov 21, 2026, 11:06 AM
- analyzed
- Nov 21, 2026, 11:07 AM
- weekly installs
- 16,111
hxxps://github[.]com/nexustechpro2/baileys Request takedown / dispute →Related advisories
- @zervonex/baileys@4.0.9-patch.1 same package
- @zervonex/baileys@4.0.8 same package
- @zervonex/baileys@4.0.7 same package
- @zervonex/baileys@4.0.6-final same package
- @zervonex/baileys@4.0.5-final same package
- @zervonex/baileys@4.0.4-final same package
- @zervonex/baileys@4.0.4 same package
- @izi-coder/baileys@2.0.5
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.