MAL-2026-10684: Malicious code in react-hook-scripts (npm)
The npm package react-hook-scripts version 5.4.2 contains malicious code that fetches and executes arbitrary JavaScript from a remote server. This remote code execution occurs via the package's default export 'getPlugin', which downloads a JSON payload from a hardcoded URL and runs the 'credits' field as code with full Node.js privileges. The malicious payload includes dependencies consistent with credential and host fingerprint stealing. Any use of the package's API triggers execution of attacker-controlled code, which can be changed at any time by the server operator.
AI Analysis
Technical Summary
The react-hook-scripts package version 5.4.2 includes a backdoor in its default export 'getPlugin' that fetches a JSON document from a hardcoded remote endpoint. It extracts the 'credits' field from the JSON and executes it as JavaScript code using the Function constructor, providing access to Node.js globals such as require, process, and Buffer. The remote URL is constructed from concatenated fragments and the request includes a custom header to disguise the malicious fetch as an SVG icon retrieval. The fetched payload relies on dependencies like @primno/dpapi, better-sqlite3, and node-machine-id, indicating functionality to steal credentials and host fingerprints. This design allows the attacker to execute arbitrary code on any system that installs and calls the package's API, with the payload modifiable at any time by the attacker.
Potential Impact
Any environment that installs and uses react-hook-scripts version 5.4.2 is at risk of arbitrary remote code execution. This can lead to credential theft, host fingerprinting, and potentially full system compromise. The attacker can change the payload at will, enabling ongoing malicious activity. There are no known exploits in the wild at this time, but the risk is significant due to the nature of the code execution and the sensitive data targeted.
Mitigation Recommendations
No official patch or remediation is currently available for react-hook-scripts version 5.4.2. Users should immediately cease using this package version and remove it from their projects. Avoid installing or running code from this package until a trusted, verified version is released. Monitor vendor advisories for updates. Since this is not a cloud service, remediation depends on user action to remove the malicious package.
MAL-2026-10684: Malicious code in react-hook-scripts (npm)
Description
The npm package react-hook-scripts version 5.4.2 contains malicious code that fetches and executes arbitrary JavaScript from a remote server. This remote code execution occurs via the package's default export 'getPlugin', which downloads a JSON payload from a hardcoded URL and runs the 'credits' field as code with full Node.js privileges. The malicious payload includes dependencies consistent with credential and host fingerprint stealing. Any use of the package's API triggers execution of attacker-controlled code, which can be changed at any time by the server operator.
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 react-hook-scripts package version 5.4.2 includes a backdoor in its default export 'getPlugin' that fetches a JSON document from a hardcoded remote endpoint. It extracts the 'credits' field from the JSON and executes it as JavaScript code using the Function constructor, providing access to Node.js globals such as require, process, and Buffer. The remote URL is constructed from concatenated fragments and the request includes a custom header to disguise the malicious fetch as an SVG icon retrieval. The fetched payload relies on dependencies like @primno/dpapi, better-sqlite3, and node-machine-id, indicating functionality to steal credentials and host fingerprints. This design allows the attacker to execute arbitrary code on any system that installs and calls the package's API, with the payload modifiable at any time by the attacker.
Potential Impact
Any environment that installs and uses react-hook-scripts version 5.4.2 is at risk of arbitrary remote code execution. This can lead to credential theft, host fingerprinting, and potentially full system compromise. The attacker can change the payload at will, enabling ongoing malicious activity. There are no known exploits in the wild at this time, but the risk is significant due to the nature of the code execution and the sensitive data targeted.
Mitigation Recommendations
No official patch or remediation is currently available for react-hook-scripts version 5.4.2. Users should immediately cease using this package version and remove it from their projects. Avoid installing or running code from this package until a trusted, verified version is released. Monitor vendor advisories for updates. Since this is not a cloud service, remediation depends on user action to remove the malicious package.
Technical Details
- Gcve Source
- db.gcve.eu
- Osv Id
- MAL-2026-10684
- Osv Schema Version
- 1.7.4
- Aliases
- []
- Ecosystems
- ["npm"]
- Database Specific Severity
- null
- Cvss Version
- null
Threat ID: 6a58b51b68715ace43db478e
Added to database: 07/16/2026, 10:40:27 UTC
Last enriched: 07/16/2026, 14:30:48 UTC
Last updated: 07/16/2026, 19:22:38 UTC
Views: 8
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.