Skip to main content

Malicious code in pybitjs (PyPI)

0
Critical
Published: 08/26/2026 (08/26/2026, 19:21:41 UTC)
Source: GCVE Database
Product: pybitjs

Description

The pybitjs package on PyPI contains malicious code that executes during installation and every Python interpreter startup. It uses obfuscated JavaScript to fetch attacker-controlled payloads via a command-and-control mechanism leveraging Ethereum blockchain transactions to dynamically determine the C2 server IP. The payload downloads and executes further malicious code, consistent with campaigns attributed to the Lazarus APT group. This allows arbitrary code execution on the host system of anyone installing or running Python with this package present.

Affected software

PyPIghsa
pybitjs
Affected versions
=0.1.0

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/10/2026, 06:38:12 UTC

Technical Analysis

The pybitjs PyPI package's setuptools commands invoke a Node.js script during pip install, which writes a .pth file causing the Node.js payload to run on every Python startup. The embedded JavaScript is heavily obfuscated and implements a C2 mechanism by querying Ethereum JSON-RPC endpoints for transactions involving a hardcoded Ethereum address. It extracts an IP address from the blockchain transaction data, fetches an XOR-encrypted payload from that IP, decrypts it, and executes it via eval and detached Node.js processes. This design allows the attacker to dynamically control the C2 server via blockchain transactions, enabling arbitrary remote code execution on affected hosts. The behavior and IoCs align with Lazarus APT/PolinRider campaigns.

Potential Impact

Installation or execution of Python with the pybitjs package present results in arbitrary attacker-controlled code execution on the host system. The attacker can dynamically change the C2 server IP via blockchain transactions, enabling persistent and flexible remote control. This compromises the confidentiality, integrity, and availability of the affected system.

Mitigation Recommendations

No official patch or remediation is currently documented. Users should immediately uninstall the pybitjs package if present and avoid installing or running Python environments containing this package. Monitor for and remove any pybitjs.pth files and related Node.js processes. Check vendor advisories or PyPI for updates or removal notices. Patch status is not yet confirmed — check the vendor advisory for current remediation guidance.

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-14545
Osv Schema Version
1.7.4
Ecosystems
["PyPI"]

Threat ID: 6a905405acd9273b49697318

Added to database: 08/27/2026, 15:13:09 UTC

Last enriched: 09/10/2026, 06:38:12 UTC

Last updated: 10/04/2026, 06:50:16 UTC

Views: 100

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