Skip to main content

Malicious code in twapfetch (npm)

0
Critical
Published: 08/19/2026 (08/19/2026, 01:16:39 UTC)
Source: GCVE Database
Product: twapfetch

Description

The npm package twapfetch versions 1.1.0 and 1.1.1 contains a malicious postinstall script that downloads and executes arbitrary code during installation. The package's advertised functionality does not match its actual behavior, which is typical of install-time malware droppers. Installing this package can lead to full system compromise.

Affected software

npmghsa
twapfetch
Affected versions
=1.1.0=1.1.1

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

AILast updated: 09/11/2026, 09:04:32 UTC

Technical Analysis

The twapfetch npm package (versions 1.1.0 and 1.1.1) includes a postinstall script that, upon npm install, downloads a tarball from a URL controlled by environment variables or the package.json homepage field. This tarball is extracted and installed without any version pinning, hash verification, or signature checks, allowing arbitrary code execution on the installer's machine. The package's advertised purpose as a Polymarket Chainlink TWAP WebSocket client is not implemented; instead, the postinstall script acts as a malicious dropper. This behavior indicates that any system installing this package is at risk of full compromise.

Potential Impact

Any computer with this package installed or running should be considered fully compromised. Attackers may have gained full control over the system, potentially accessing all secrets and keys stored on it. Removing the package alone does not guarantee removal of all malicious components introduced during installation.

Mitigation Recommendations

Immediate removal of the twapfetch package versions 1.1.0 and 1.1.1 is recommended. All secrets and keys stored on the compromised system should be rotated from a separate, trusted machine. Due to the nature of the compromise, a full system investigation and remediation may be necessary. No official patch or fix is indicated; users should avoid installing this package.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
MAL-2026-14197
Osv Schema Version
1.7.4
Ecosystems
["npm"]

Threat ID: 6a85b4c7acd9273b49252880

Added to database: 08/19/2026, 13:51:03 UTC

Last enriched: 09/11/2026, 09:04:32 UTC

Last updated: 10/02/2026, 13:52:38 UTC

Views: 23

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

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

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses