Malicious code in request-easy-validator (npm)
The npm package 'request-easy-validator' impersonates the popular 'request' package and contains malicious code that enables remote code execution. When its exported middleware function is invoked, it silently spawns a detached Node.js process that fetches and executes attacker-controlled code from a mutable URL. This allows an attacker to execute arbitrary Node.js code with full module access on any server using this package. Multiple specific versions of the package are affected.
AI Analysis
Technical Summary
The 'request-easy-validator' npm package is a malicious clone of the legitimate 'request' package. Its main module exports a middleware function that, upon invocation, launches a detached child Node.js process running 'lib/callers.js'. This child process makes an HTTPS GET request to an attacker-controlled paste host URL with a secret header, retrieves a '.Cookie' field from the response, and executes it as Node.js code using 'new Function.constructor' with live 'require' access. Because the payload URL is mutable, the attacker can change the executed code at any time without republishing the package, enabling persistent arbitrary remote code execution on any system using these versions of the package.
Potential Impact
Any server or environment that installs and runs the affected versions of 'request-easy-validator' and invokes its middleware function is vulnerable to arbitrary remote code execution controlled by the attacker. This can lead to full compromise of the host system, data theft, or further malicious activity. The attacker can update the payload at will, maintaining persistent control without needing to update the package itself.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately remove 'request-easy-validator' from their dependencies and replace it with the legitimate 'request' package or a trusted alternative. Avoid invoking the middleware function from this package. Monitor for any unexpected child processes or network requests to suspicious external URLs. Patch status is not yet confirmed — check the vendor advisory or trusted sources for updates.
Malicious code in request-easy-validator (npm)
Description
The npm package 'request-easy-validator' impersonates the popular 'request' package and contains malicious code that enables remote code execution. When its exported middleware function is invoked, it silently spawns a detached Node.js process that fetches and executes attacker-controlled code from a mutable URL. This allows an attacker to execute arbitrary Node.js code with full module access on any server using this package. Multiple specific versions of the package are affected.
Affected software
pkg:npm/request-easy-validatorRun 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 'request-easy-validator' npm package is a malicious clone of the legitimate 'request' package. Its main module exports a middleware function that, upon invocation, launches a detached child Node.js process running 'lib/callers.js'. This child process makes an HTTPS GET request to an attacker-controlled paste host URL with a secret header, retrieves a '.Cookie' field from the response, and executes it as Node.js code using 'new Function.constructor' with live 'require' access. Because the payload URL is mutable, the attacker can change the executed code at any time without republishing the package, enabling persistent arbitrary remote code execution on any system using these versions of the package.
Potential Impact
Any server or environment that installs and runs the affected versions of 'request-easy-validator' and invokes its middleware function is vulnerable to arbitrary remote code execution controlled by the attacker. This can lead to full compromise of the host system, data theft, or further malicious activity. The attacker can update the payload at will, maintaining persistent control without needing to update the package itself.
Mitigation Recommendations
No official patch or remediation is currently documented. Users should immediately remove 'request-easy-validator' from their dependencies and replace it with the legitimate 'request' package or a trusted alternative. Avoid invoking the middleware function from this package. Monitor for any unexpected child processes or network requests to suspicious external URLs. 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-2798
- Osv Schema Version
- 1.7.4
- Aliases
- ["GHSA-6h5g-9vvm-x5jj"]
- Ecosystems
- ["npm"]
Threat ID: 6a96f317acd9273b49e49480
Added to database: 09/01/2026, 15:45:27 UTC
Last enriched: 09/08/2026, 12:40:50 UTC
Last updated: 09/08/2026, 12:40:50 UTC
Views: 3
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.