npm

The @alannxd/baileys npm Supply Chain Attack

Updated 16 Nov 2026 · Incident date 1 Sept 2025

GitHub marks 27 versions of @alannxd/baileys, a fork of the Baileys WhatsApp library, as malware, and Amazon Inspector reports an import-time beacon in version 6.1.3.

GitHub published malware advisory GHSA-7345-fjw8-x55w for @alannxd/baileys on 21 October 2026. The package is a fork of the Baileys WhatsApp library.

What happened

The npm account alannxd published a Baileys fork that GitHub and OpenSSF list as malware.

  • The first flagged version, 2.1.2, went to npm on 1 September 2025. The last, 6.2.8, went up on 29 September 2026.
  • OpenSSF record MAL-2026-18120 carries an Amazon Inspector analysis of version 6.1.3. It reports that lib/index.js sends an HTTPS GET to a raw.githubusercontent.com URL on every require and logs one string from the reply.
  • The same analysis reports that package.json aliases libsignal to @alannxd/libsignal-node at its latest tag.
  • Amazon Inspector reports no credential harvesting, no environment scraping and no remote code execution in the code it traced.
  • On 21 October 2026 npm replaced the package with the holding version 0.0.1-security.

The npm tarballs now return 404, so the code was unavailable for inspection. The GitHub advisory text says to treat any computer that ran the package as fully compromised.

Affected versions

  • Versions 2.1.2, 2.1.3 and 2.1.4.
  • Versions 3.0.0 and 3.0.3.
  • Versions 4.0.3, 4.0.4 and 4.0.5.
  • Versions 5.0.5 and 5.0.6.
  • Versions 6.0.0, 6.0.1, 6.0.2, 6.0.3, 6.0.4, 6.0.5, 6.0.6 and 6.0.9.
  • Versions 6.1.0, 6.1.1, 6.1.2, 6.1.3, 6.1.4, 6.1.6 and 6.1.7.
  • Versions 6.2.7 and 6.2.8.
  • GitHub lists no patched version. Versions 1.1.8 to 2.1.1 are not in either advisory.

Indicators of compromise

  • https://raw.githubusercontent.com/alannzxd/xclient/refs/heads/main/information.json
  • Dependency alias npm:@alannxd/libsignal-node@latest
  • Package @alannxd/baileys from the npm account alannxd

How to check

Run this command in each project folder to list an installed copy.

npm ls @alannxd/baileys

Search your lockfiles for any package from the alannxd account. This command only reads files.

grep -n "@alannxd/" package-lock.json yarn.lock pnpm-lock.yaml 2>/dev/null

What to do now

  1. Remove @alannxd/baileys from the project and from its lockfile.
  2. Treat any computer that installed or ran the package as fully compromised, as the GitHub advisory says.
  3. Rotate every secret on that computer. Do it from a different computer.
  4. Removing the package alone is not enough, according to the GitHub advisory. It can leave other malicious software in place.

What Vigilance would show

Vigilance checks each update before it installs. This is what a customer sees, rebuilt from the facts on this page.

On the computer, at install

Vigilance blocked `@alannxd/baileys` 2.1.2. This version is too new or changed in a way Vigilance must check first.
The last safe version is 2.1.1. Install that version.

In the owner report

Bad update

@alannxd/baileys 2.1.2

This update now downloads from the internet. The version before it did not.

  1. Ask the AI tool to swap @alannxd/baileys to 2.1.1. That is the last safe version.

Frequently asked questions

Is @alannxd/baileys malware?

GitHub advisory GHSA-7345-fjw8-x55w marks 27 versions, 2.1.2 to 6.2.8, as malware. npm replaced the package with a security holding package on 21 October 2026.

What does @alannxd/baileys do when it loads?

Amazon Inspector reports that version 6.1.3 contacts a GitHub raw URL on every import and logs one string from the reply. It reports no credential harvesting and no remote code execution.

Sources

  1. osv.dev/vulnerability/MAL-2026-18120
  2. github.com/advisories/GHSA-7345-fjw8-x55w
  3. registry.npmjs.org/@alannxd/baileys

More supply chain attacks

All 148 attacks in the library · npm supply chain attacks · How to prevent supply chain attacks

Check the next update before you install it

Vigilance compares the version you trust with the new one. It names the one file that gained a power the old version did not have.

Start the free 14-day trialBrowse the attack library