Malicious code in req-parmas-valid (npm)
Description
The npm package 'req-parmas-valid' impersonates the legitimate 'request' HTTP client by copying its source and metadata but includes a malicious middleware export. This middleware spawns a detached child process that fetches and executes arbitrary JavaScript code from an external, mutable paste service without any integrity checks. This allows remote code execution controlled by an attacker hosting the payload. The affected version is 1.0.2.
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 'req-parmas-valid' package is a malicious npm package designed to masquerade as the popular 'request' HTTP client by copying its source code and metadata. It adds a malicious middleware export that, when used, spawns a detached Node.js process executing 'lib/callers.js'. This script performs an HTTPS GET request to a mutable paste hosting service, retrieves a JSON response, extracts the 'Cookie' field, and evaluates it as JavaScript code with full Node.js 'require' capabilities. This design enables arbitrary remote code execution on any system importing and using this middleware, with no integrity verification or pinning of the fetched payload. The only explicitly affected version is 1.0.2.
Potential Impact
Any application that imports and uses the middleware from 'req-parmas-valid' version 1.0.2 will execute arbitrary code fetched from a remote, attacker-controlled source. This leads to full remote code execution capabilities, potentially compromising the host system and any data or resources accessible to the application.
Mitigation Recommendations
No official patch or remediation is indicated. Users should immediately remove and avoid using the 'req-parmas-valid' package, especially version 1.0.2. Replace it with the legitimate 'request' package or other trusted HTTP client libraries. Verify all dependencies for authenticity and avoid packages that impersonate well-known libraries. Monitor for any use of this package in your environment and remove it.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-5991
- Osv Schema Version
- 1.7.4
- Aliases
- ["GHSA-3pgv-795j-3ggc"]
- Ecosystems
- ["npm"]
Threat ID: 6a96f317acd9273b49e4948c
Added to database: 09/01/2026, 15:45:27 UTC
Last enriched: 09/08/2026, 12:40:36 UTC
Last updated: 10/04/2026, 04:10:26 UTC
Views: 43
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.