CVE-2026-48161: CWE-506: Embedded Malicious Code in dai-shi react18-use
The react18-use package contained malicious commits on its default branch for a brief period on 2026-05-19. These commits introduced a postinstall script that fetched and executed attacker-controlled code on developer machines during npm install, bypassing TLS verification and avoiding execution in CI/cloud environments. The malicious commits were removed by force-push, but local clones and forks may still contain them. The package was not published to npm, but affected checkouts remain dangerous. Users who ran npm install on an affected checkout should consider their machines compromised and take remediation steps.
AI Analysis
Technical Summary
CVE-2026-48161 describes a supply chain attack in the react18-use package where malicious commits were introduced on the default branch between 2026-05-19 01:07:01 and 15:20:43. These commits added a postinstall script (src/install.js) that fetched a JavaScript payload from an attacker-controlled HTTPS endpoint with TLS verification disabled and executed it with require available. The payload was designed to run only on developer workstations, skipping CI and cloud environments. The malicious commits were removed by force-push, but local clones and forks may still contain them. The second-stage payload is unavailable, but full compromise of the affected developer machine is assumed. The package was never published to npm, limiting exposure to those who cloned the repository directly or used direct SHA URLs.
Potential Impact
The vulnerability allows remote attacker-controlled code execution on developer machines during npm install of an affected checkout. This can lead to full compromise of the developer environment with the permissions of the user running the Node process. Credentials accessible from the compromised machine may be stolen or misused. The attack specifically targets developer workstations, avoiding CI and cloud environments, thus potentially enabling further supply chain or internal network compromise.
Mitigation Recommendations
The malicious commits were removed by force-push, but no official patch or remediation is available since the package was not published to npm. Users who ran npm install on an affected checkout on or after 2026-05-19 01:07:01 should treat their machines as compromised. Recommended actions include rotating all credentials accessible from the machine, auditing account activity since the compromise date, and cleaning or recloning local repositories to remove the malicious commits. Avoid using direct SHA URLs or local clones that may contain the malicious commits.
CVE-2026-48161: CWE-506: Embedded Malicious Code in dai-shi react18-use
Description
The react18-use package contained malicious commits on its default branch for a brief period on 2026-05-19. These commits introduced a postinstall script that fetched and executed attacker-controlled code on developer machines during npm install, bypassing TLS verification and avoiding execution in CI/cloud environments. The malicious commits were removed by force-push, but local clones and forks may still contain them. The package was not published to npm, but affected checkouts remain dangerous. Users who ran npm install on an affected checkout should consider their machines compromised and take remediation steps.
CVSS v4.0
Score 9.3critical
Weaknesses
AI-Powered Analysis
Machine-generated threat intelligence
Technical Analysis
CVE-2026-48161 describes a supply chain attack in the react18-use package where malicious commits were introduced on the default branch between 2026-05-19 01:07:01 and 15:20:43. These commits added a postinstall script (src/install.js) that fetched a JavaScript payload from an attacker-controlled HTTPS endpoint with TLS verification disabled and executed it with require available. The payload was designed to run only on developer workstations, skipping CI and cloud environments. The malicious commits were removed by force-push, but local clones and forks may still contain them. The second-stage payload is unavailable, but full compromise of the affected developer machine is assumed. The package was never published to npm, limiting exposure to those who cloned the repository directly or used direct SHA URLs.
Potential Impact
The vulnerability allows remote attacker-controlled code execution on developer machines during npm install of an affected checkout. This can lead to full compromise of the developer environment with the permissions of the user running the Node process. Credentials accessible from the compromised machine may be stolen or misused. The attack specifically targets developer workstations, avoiding CI and cloud environments, thus potentially enabling further supply chain or internal network compromise.
Mitigation Recommendations
The malicious commits were removed by force-push, but no official patch or remediation is available since the package was not published to npm. Users who ran npm install on an affected checkout on or after 2026-05-19 01:07:01 should treat their machines as compromised. Recommended actions include rotating all credentials accessible from the machine, auditing account activity since the compromise date, and cleaning or recloning local repositories to remove the malicious commits. Avoid using direct SHA URLs or local clones that may contain the malicious commits.
Technical Details
- Data Version
- 5.2
- Assigner Short Name
- GitHub_M
- Date Reserved
- 2026-05-20T23:12:43.032Z
- Cvss Version
- 4.0
- State
- PUBLISHED
- Remediation Level
- null
Threat ID: 6a7a53c0bf8831d539aba087
Added to database: 08/10/2026, 22:42:08 UTC
Last enriched: 08/10/2026, 22:56:08 UTC
Last updated: 08/10/2026, 23:23:19 UTC
Views: 6
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.