Malicious code in @fhkry/baileys (npm)
The @fhkry/baileys npm package (version 8.0.13) is a malicious fork of the Baileys WhatsApp Web library. It silently performs unauthorized WhatsApp newsletter subscription actions on the user's authenticated WhatsApp account by fetching a remote, mutable list controlled by the attacker. The malicious behavior is obfuscated in the source code to evade detection. Any application using this package and calling makeWASocket() unknowingly acts as a node amplifying the attacker's newsletter subscriptions. The package compromises the host system, potentially exposing all stored secrets and keys.
AI Analysis
Technical Summary
The @fhkry/baileys package at version 8.0.13 contains malicious code that, on each WebSocket connection, fetches a remote JSON list from an obfuscated URL controlled by the attacker. It then issues WhatsApp newsletter subscription mutations against the authenticated user's session, effectively hijacking the account to follow attacker-chosen newsletters. The code uses obfuscation techniques such as String.fromCharCode and base64+XOR encoding to hide its true intent. The remote list is mutable without integrity checks, allowing the attacker to change the newsletters dynamically. The default pairing code and author attribution confirm single-author malicious intent. This package compromises any system it is installed on, potentially exposing all secrets and keys stored on that system.
Potential Impact
Systems with this package installed are fully compromised. The attacker gains the ability to silently manipulate the victim's WhatsApp account to subscribe to newsletters controlled by the attacker, potentially enabling further abuse or information gathering. Because the package runs code fetched from a mutable remote source without integrity verification, the attacker can change payloads at will. The compromise extends to the host system, risking exposure of stored secrets and keys. Removal of the package alone may not fully restore system integrity due to potential persistence of malicious artifacts.
Mitigation Recommendations
No official patch or fix is available for this malicious package. The recommended mitigation is immediate removal of the @fhkry/baileys package version 8.0.13 from all systems. All secrets and keys stored on affected systems should be rotated from a clean, uncompromised environment. Users should avoid using this package and verify the authenticity of Baileys library sources. Due to the full compromise risk, a thorough system integrity check and potential rebuild is advised.
Malicious code in @fhkry/baileys (npm)
Description
The @fhkry/baileys npm package (version 8.0.13) is a malicious fork of the Baileys WhatsApp Web library. It silently performs unauthorized WhatsApp newsletter subscription actions on the user's authenticated WhatsApp account by fetching a remote, mutable list controlled by the attacker. The malicious behavior is obfuscated in the source code to evade detection. Any application using this package and calling makeWASocket() unknowingly acts as a node amplifying the attacker's newsletter subscriptions. The package compromises the host system, potentially exposing all stored secrets and keys.
Affected software
Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
The @fhkry/baileys package at version 8.0.13 contains malicious code that, on each WebSocket connection, fetches a remote JSON list from an obfuscated URL controlled by the attacker. It then issues WhatsApp newsletter subscription mutations against the authenticated user's session, effectively hijacking the account to follow attacker-chosen newsletters. The code uses obfuscation techniques such as String.fromCharCode and base64+XOR encoding to hide its true intent. The remote list is mutable without integrity checks, allowing the attacker to change the newsletters dynamically. The default pairing code and author attribution confirm single-author malicious intent. This package compromises any system it is installed on, potentially exposing all secrets and keys stored on that system.
Potential Impact
Systems with this package installed are fully compromised. The attacker gains the ability to silently manipulate the victim's WhatsApp account to subscribe to newsletters controlled by the attacker, potentially enabling further abuse or information gathering. Because the package runs code fetched from a mutable remote source without integrity verification, the attacker can change payloads at will. The compromise extends to the host system, risking exposure of stored secrets and keys. Removal of the package alone may not fully restore system integrity due to potential persistence of malicious artifacts.
Mitigation Recommendations
No official patch or fix is available for this malicious package. The recommended mitigation is immediate removal of the @fhkry/baileys package version 8.0.13 from all systems. All secrets and keys stored on affected systems should be rotated from a clean, uncompromised environment. Users should avoid using this package and verify the authenticity of Baileys library sources. Due to the full compromise risk, a thorough system integrity check and potential rebuild is advised.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-4803
- Osv Schema Version
- 1.7.4
- Aliases
- ["GHSA-779h-825r-3p44"]
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a577edd68715ace43b400b2
Added to database: 07/15/2026, 12:36:45 UTC
Last enriched: 07/15/2026, 12:50:26 UTC
Last updated: 07/29/2026, 12:57:56 UTC
Views: 15
Community Reviews
0 reviewsCrowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.
Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.
Actions
Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.
External Links
Need more coverage?
Upgrade to Pro Console for AI refresh and higher limits.
For incident response and remediation, OffSeq services can help resolve threats faster.
Latest Threats
Check if your credentials are on the dark web
Instant breach scanning across billions of leaked records. Free tier available.