8 Malicious PyPI Packages Use Python Dependencies as Keys to Unlock Hidden Malware
Malicious PyPI packages use Python dependencies as keys to unlock hidden malware via DevGating technique.
A campaign targeting the Python Package Index (PyPI) uses a novel technique called DevGating, where the victim's Python dependencies act as a key to decrypt malicious payloads. The campaign, active since September 25, 2026, involves eight packages split across different PyPI accounts to evade detection. The malware checks for specific loaded dependencies, like those from the 'requests' package, to derive the decryption key and establish persistence via a .pth file.
AI summary of the linked source. Not reviewed by an editor. How this works
Run PyPI?
Get an email when a new story names PyPI, usually within the hour.
Free. Your list stays private and never appears in a subject line. One click stops it. How Vendor Watch worksPrivacy
The lesson from this incident
Full lessonEight malicious PyPI packages employed a novel 'DevGating' technique, using the victim's installed Python dependencies as decryption keys to unlock hidden malware payloads — meaning the malicious code only activates in a matching target environment, making static analysis nearly useless. The packages were deliberately spread across multiple PyPI accounts to avoid pattern-based detection. This attack demonstrates how open-source package ecosystems remain a high-value supply chain attack vector, particularly when developers install packages without verifying their provenance. The persistence mechanism via a .pth file ensures the malware survives reboots and package removal, compounding the damage once a system is compromised.
What helps against this
How we list vendors- Vulnerability scanning and prioritisation
You know which systems are vulnerable, and which ones to fix first.
- Threat intelligence
Attack campaigns reach your sector, suppliers or software before your team hears about them.
- Software supply chain security
Malicious and vulnerable open-source packages are caught before they ship.
Indicators of Compromise
Addresses and file hashes are copied from the publisher's page by pattern matching. Names are picked by AI. On stories from before 17 November 2026, some addresses and hashes were picked by AI too. Not reviewed by an editor. How this works
- malware: DevGating
- ip: 194.150.166.244
- ip: 18.143.168.96