Every published release of the npm package @jexkcode/baileys, a fork of the Baileys WhatsApp library, carries malicious code.
GitHub published malware advisory GHSA-qr3w-xq4p-6575 on 30 November 2026. npm replaced the package with a security holding package the same day.
What happened
GitHub marks the npm package @jexkcode/baileys, a fork of the Baileys WhatsApp library, as malicious code.
- The package published versions
1.1.4to1.3.8, from 2 October 2026 to 26 November 2026. - OpenSSF record MAL-2026-18850 credits CyberXYZ and InvisiRisk as finders. It tags the package CWE-506, embedded malicious code.
- The OpenSSF record states that code in
lib/Utils/auto-follow.jssends the WhatsApp w:mex FOLLOW query for channel120363405612723183@newsletter. It uses the victim's own session when the socket connects. The record ties the package to the PhantomSub family. - npm removed the 1.x versions on 30 November 2026, so the code was unavailable for inspection. This page states only what the advisory and registry records report.
- GitHub lists no patched version.
Affected versions
- GitHub and OpenSSF list
1.1.4,1.1.5,1.2.0and1.3.0to1.3.8. - Both records also list
0.0.0-stage. The registry shows it as an npm placeholder stub from 30 November 2026. 0.0.1-securityis the holding package npm published on 30 November 2026. It is not a fix.
Indicators of compromise
- Package
@jexkcode/baileysinpackage.json, a lockfile ornode_modules. - A WhatsApp channel follow for
120363405612723183@newsletter, as the OpenSSF record describes. - File
lib/Utils/auto-follow.jswith SHA-2561be42e76af3018a08068e8d8c257b0a6cb57fa85e74d196e61b8b3a38417c013, from OpenSSF record MAL-2026-18850.
How to check
Run this command in each project folder to list an installed copy.
npm ls @jexkcode/baileys
Search your lockfiles for the package. This command only reads files.
grep -n '@jexkcode/' package-lock.json yarn.lock pnpm-lock.yaml
Check past CI build logs and lockfile history for any install since 2 October 2026. A clean install today cannot rule out earlier exposure.
What to do now
- Remove
@jexkcode/baileysfrom the project and from its lockfile. - Treat any computer that installed or ran the package as fully compromised, as the GitHub advisory states.
- Rotate every secret and key on that computer. Do it from a different computer.
- The advisory warns that removing the package cannot guarantee removal of all malicious software it installed. Rebuild the machine from a clean image.
What Vigilance would show
These examples show an install hold and the corresponding owner report.
Example install message
Vigilance blocked `@jexkcode/baileys` 1.3.8. This version is too new or changed in a way Vigilance must check first.
Example owner report
Bad update
@jexkcode/baileys 1.3.8
The npm package @jexkcode/baileys used the installer's WhatsApp session to follow a channel the publisher chose, without telling the user.
No security team? See who reads the alert.
Frequently asked questions
Is @jexkcode/baileys the official Baileys library?
No. It is a separate npm package that forks the Baileys WhatsApp library code. The advisory covers @jexkcode/baileys only.
What did the malicious code do?
The code is not available for inspection because npm removed the 1.x versions. OpenSSF record MAL-2026-18850 says the package follows a WhatsApp channel from the victim's own session. GitHub advisory GHSA-qr3w-xq4p-6575 says to treat any computer that ran the package as fully compromised.
Are the affected versions still on npm?
No. npm removed the 1.x versions and set the latest tag to the security holding version 0.0.1-security on 30 November 2026. Copies in lockfiles or caches can still resolve, so check your projects.
Sources
Send this page to the person who looks after AI at your company.