Malicious code in loading-sessions (npm)
The loading-sessions npm package version 6.13.2 is a malicious typosquatting package impersonating the pino logger. It executes attacker-controlled remote code by fetching and running JavaScript from a hardcoded URL with full Node.js require access, enabling silent retries and detached execution. This behavior constitutes a remote code execution threat via a malicious package.
AI Analysis
Technical Summary
The loading-sessions package (version 6.13.2) impersonates the legitimate pino logger by exporting similar modules and filenames. When its middleware is invoked, it spawns a detached child process that base64-decodes a hardcoded URL disguised as an environment variable, fetches a JSON document from this URL, and extracts a 'cookie' string. This string is passed to a new Function constructor and executed with Node.js require access, allowing arbitrary code execution. The package retries fetching up to five times silently and uses base64-decoded headers from disguised environment variables. This is a classic remote-code dropper hidden behind a typosquatting lure.
Potential Impact
This malicious package enables remote code execution on any system that installs and runs it, allowing attackers to execute arbitrary code with the privileges of the Node.js process. The attacker-controlled payload is fetched dynamically, making detection and prevention difficult once the package is installed and executed.
Mitigation Recommendations
No official patch or remediation is currently available. Users should avoid installing or using the loading-sessions package version 6.13.2. Verify package authenticity before installation, prefer official packages, and remove any instances of this malicious package from your environment. Monitor for suspicious child processes spawned by Node.js applications. Patch status is not yet confirmed — check the vendor advisory or trusted sources for updates.
Malicious code in loading-sessions (npm)
Description
The loading-sessions npm package version 6.13.2 is a malicious typosquatting package impersonating the pino logger. It executes attacker-controlled remote code by fetching and running JavaScript from a hardcoded URL with full Node.js require access, enabling silent retries and detached execution. This behavior constitutes a remote code execution threat via a malicious package.
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 loading-sessions package (version 6.13.2) impersonates the legitimate pino logger by exporting similar modules and filenames. When its middleware is invoked, it spawns a detached child process that base64-decodes a hardcoded URL disguised as an environment variable, fetches a JSON document from this URL, and extracts a 'cookie' string. This string is passed to a new Function constructor and executed with Node.js require access, allowing arbitrary code execution. The package retries fetching up to five times silently and uses base64-decoded headers from disguised environment variables. This is a classic remote-code dropper hidden behind a typosquatting lure.
Potential Impact
This malicious package enables remote code execution on any system that installs and runs it, allowing attackers to execute arbitrary code with the privileges of the Node.js process. The attacker-controlled payload is fetched dynamically, making detection and prevention difficult once the package is installed and executed.
Mitigation Recommendations
No official patch or remediation is currently available. Users should avoid installing or using the loading-sessions package version 6.13.2. Verify package authenticity before installation, prefer official packages, and remove any instances of this malicious package from your environment. Monitor for suspicious child processes spawned by Node.js applications. Patch status is not yet confirmed — check the vendor advisory or trusted sources for updates.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-10471
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a55ffa768715ace432f96f2
Added to database: 07/14/2026, 09:21:43 UTC
Last enriched: 07/14/2026, 09:54:34 UTC
Last updated: 07/26/2026, 11:49:02 UTC
Views: 11
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.