@japofc/baileys@2.4.9
Malicious code in @japofc/baileys (npm)
Analysis
@japofc/baileys@2.4.9 is a WhatsApp Web automation fork republished under the unofficial @japofc scope with the same package basename as @whiskeysockets/baileys. Its package.json declares a runtime dependency on "@cacheable/node-cache": "^3.0.1", a semver range that resolves to a known-malicious release of that package, so a fresh install of this package pulls the compromised version into the installer's dependency tree; the import is real (lib/Socket/messages-send.js, lib/Socket/messages-recv.js and lib/Socket/chats.js all import NodeCache from it). The package also exact-pins an optional native addon, "whatsapp-rust-bridge": "0.5.5", which is loaded via dynamic import in lib/Utils/lt-hash.js and lib/Utils/crypto.js and therefore executes native code in the host process when app-state/crypto helpers are used. Otherwise the tarball is a large, documented WhatsApp library (26MB, WAProto protobuf bundle, lib/assets/wasm/whatsapp.wasm); its own network calls target web[.]whatsapp[.]com and, for the opt-in voice-note transcription provider, api[.]openai[.]com with the caller's own key. No credential-harvesting code was found in this tarball; the exposure for installers comes from the malicious dependency pulled in at install time and from the impersonated scope.
- analyzed by
- Leitwacht
- first seen
- Nov 18, 2026, 05:21 PM
- analyzed
- Nov 18, 2026, 05:23 PM
hxxps://github[.]com/JAPofc/baileys Request takedown / dispute →Related advisories
- atlassian-wallboard-plugin@10.0.0
- @basis-theory-elements/api-client@99.9.1
- @rizzkezik/bailss@1.0.0
- @rizzkezik/bailss@1.2.0
- @rizzkezik/bailseys@6.7.10
- @silent404/baileys@7.0.4
- lianrouter@2.3.4
- @silent404/baileys@7.0.2
Independently detected by the Leitwacht supply-chain probe. IOCs are defanged. Published CC0. Think this is a mistake? See the dispute policy.