Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…

Malicious code in happy-dlscord.js (npm)

0
Critical
Published: 05/25/2026 (05/25/2026, 19:02:13 UTC)
Source: GCVE Database
Product: happy-dlscord.js

Description

The npm package 'happy-dlscord.js' is a typosquatting malicious package that closely mimics the legitimate 'discord.js' library but includes injected code that exfiltrates Discord bot tokens to an attacker-controlled webhook. When the client emits the 'ready' event after login, the package sends the bot token along with identifying information to a hardcoded Discord webhook URL. This compromises the bot completely, allowing an attacker to read and send messages, modify the bot account, and maintain persistence. The affected version is exactly 14.16.3. Removal of the package alone may not be sufficient as the system could be fully compromised.

Affected software

npmghsa
happy-dlscord.js
Affected versions
=14.16.3

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

AILast updated: 08/20/2026, 14:16:24 UTC

Technical Analysis

The 'happy-dlscord.js' npm package is a malicious typosquatting variant of the popular 'discord.js' library. It contains injected code in src/client/Client.js that triggers upon the client emitting the 'ready' event during login. This code sends the Discord bot token and metadata to a hardcoded attacker-controlled Discord webhook URL. This exfiltration occurs silently and compromises the bot's security, enabling full control over the bot account. The package is designed to deceive developers by closely resembling the legitimate library but includes a payload that steals credentials. The affected version is =14.16.3. Due to the nature of the compromise, any system running this package should be considered fully compromised.

Potential Impact

Any developer who installs and uses 'happy-dlscord.js' version 14.16.3 and calls client.login(token) will have their Discord bot token exfiltrated to an attacker. This results in full compromise of the Discord bot, including the ability for the attacker to read all guild messages, send messages as the bot, modify the bot's account, and maintain persistence beyond uninstalling the package. Additionally, the system running this package may be fully compromised, risking exposure of all secrets and keys stored on that computer.

Defensive Guidance

Remove the 'happy-dlscord.js' package immediately. Rotate all Discord bot tokens and any other secrets or keys stored on the affected system from a different, trusted computer. Because the package may have granted full control to an attacker, assume the system is compromised and perform a thorough security assessment and remediation. Avoid installing packages with names that are typosquatting popular libraries. Use official package sources and verify package integrity before installation.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
MAL-2026-4575
Osv Schema Version
1.7.4
Aliases
["GHSA-6gjr-97pp-w2cw"]
Ecosystems
["npm"]
Database Specific Severity
null
Cvss Version
null

Threat ID: 6a870a4facd9273b49b58507

Added to database: 08/20/2026, 14:08:15 UTC

Last enriched: 08/20/2026, 14:16:24 UTC

Last updated: 08/20/2026, 14:16:24 UTC

Views: 2

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

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

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses