Skip to main content

Malicious code in chai-plus (npm)

0
Critical
Published: 08/26/2026 (08/26/2026, 14:18:49 UTC)
Source: GCVE Database
Product: chai-plus

Description

The npm package 'chai-plus' contains malicious code that automatically executes upon requiring the module. It runs a hidden command to globally install and execute a malicious package from a dynamic DNS domain over plain HTTP, unrelated to its advertised functionality. This behavior compromises any system where the package is installed, potentially giving attackers full control. Removal of the package does not guarantee complete remediation due to possible persistent backdoors. The package name mimics a popular library, increasing the risk of inadvertent installation.

Affected software

npmghsa
chai-plus
Affected versions
=6.2.5=6.2.3=6.2.4=6.3.0=7.0.0

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: 09/07/2026, 17:55:20 UTC

Technical Analysis

The 'chai-plus' npm package includes a top-level immediately invoked function expression (IIFE) in lib/index.js that automatically runs Bootstrap.execute(). This function spawns a command to install '[email protected]' globally via npm and then executes it with hardcoded arguments pointing to a command-and-control server at 'http://coolblast.zapto.org:8888/api/x-handler'. The operation is silently executed without user consent or visible errors, contradicting comments claiming it is user-invoked. The package name closely resembles the legitimate 'chai' assertion library, increasing the likelihood of accidental installation. This behavior effectively compromises any system using the package, allowing attackers to gain full control.

Potential Impact

Any system that installs or runs 'chai-plus' is considered fully compromised. Attackers may gain complete control over the affected machine, potentially accessing all stored secrets and keys. Because the malicious code executes automatically on module load and installs additional malicious software, the integrity and confidentiality of the system are severely impacted. Simply removing the package may not eliminate all malicious components or backdoors introduced by the attacker.

Defensive Guidance

Remove the 'chai-plus' package immediately from all affected systems. Rotate all secrets, keys, and credentials that were stored or used on compromised machines from a secure, unaffected environment. Due to the high likelihood of full system compromise, consider rebuilding affected systems from trusted sources. Monitor for any signs of persistent malicious activity. No official patch or fix is available; the package itself is malicious and should not be used.

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-14533
Osv Schema Version
1.7.4
Aliases
["GHSA-2r27-f59g-4hcx"]
Ecosystems
["npm"]

Threat ID: 6a9ad4e9acd9273b49b676bd

Added to database: 09/04/2026, 14:25:45 UTC

Last enriched: 09/07/2026, 17:55:20 UTC

Last updated: 10/04/2026, 01:23:52 UTC

Views: 24

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