Malicious code in chai-as-soul (npm)
The npm package chai-as-soul versions 2.3.5 and 2.3.6 is a malicious typosquatting package that impersonates the legitimate pino package. It contains code that, upon being required, decodes a hardcoded URL and sends the entire environment variables of the host process to an attacker-controlled endpoint. It then executes arbitrary JavaScript code received from that endpoint with full module access, enabling remote code execution and exfiltration of sensitive environment data such as cloud tokens and secrets.
AI Analysis
Technical Summary
[email protected] and 2.3.6 is a typosquatting and repackaged malicious npm package mimicking pino. It includes a top-level immediately-invoked function expression (IIFE) that runs on require, which base64-decodes a hardcoded URL and sends the host's entire process environment variables via an HTTP POST request to that URL with a secret header. The response body is then executed as JavaScript code with require injected, allowing attacker-controlled code execution with full access to the Node.js module system. This results in bulk exfiltration of environment variables (including AWS, GCP, CI tokens, and other secrets) and arbitrary remote code execution on any host that loads the module.
Potential Impact
This malicious package allows attackers to exfiltrate all environment variables from the host process, potentially leaking sensitive credentials and secrets such as cloud service tokens and CI environment variables. Additionally, it enables arbitrary remote code execution within the Node.js process, which can lead to full compromise of the affected system or environment.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately remove and avoid using chai-as-soul versions 2.3.5 and 2.3.6. Verify dependencies to ensure no malicious typosquatting packages are included. Use trusted package sources and consider implementing package integrity verification. Monitor for any unexpected network connections or process behavior related to this package.
Malicious code in chai-as-soul (npm)
Description
The npm package chai-as-soul versions 2.3.5 and 2.3.6 is a malicious typosquatting package that impersonates the legitimate pino package. It contains code that, upon being required, decodes a hardcoded URL and sends the entire environment variables of the host process to an attacker-controlled endpoint. It then executes arbitrary JavaScript code received from that endpoint with full module access, enabling remote code execution and exfiltration of sensitive environment data such as cloud tokens and secrets.
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
[email protected] and 2.3.6 is a typosquatting and repackaged malicious npm package mimicking pino. It includes a top-level immediately-invoked function expression (IIFE) that runs on require, which base64-decodes a hardcoded URL and sends the host's entire process environment variables via an HTTP POST request to that URL with a secret header. The response body is then executed as JavaScript code with require injected, allowing attacker-controlled code execution with full access to the Node.js module system. This results in bulk exfiltration of environment variables (including AWS, GCP, CI tokens, and other secrets) and arbitrary remote code execution on any host that loads the module.
Potential Impact
This malicious package allows attackers to exfiltrate all environment variables from the host process, potentially leaking sensitive credentials and secrets such as cloud service tokens and CI environment variables. Additionally, it enables arbitrary remote code execution within the Node.js process, which can lead to full compromise of the affected system or environment.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately remove and avoid using chai-as-soul versions 2.3.5 and 2.3.6. Verify dependencies to ensure no malicious typosquatting packages are included. Use trusted package sources and consider implementing package integrity verification. Monitor for any unexpected network connections or process behavior related to this package.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-14343
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a885f31acd9273b493f846e
Added to database: 08/21/2026, 14:22:41 UTC
Last enriched: 08/21/2026, 14:43:42 UTC
Last updated: 08/21/2026, 21:35:03 UTC
Views: 5
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.