poc-revshellPyPI
Advisory published Updated
poc-revshell is a confirmed malicious PyPI package (MAL-2026-18378) that opens a backdoor for remote access (malicious version 0.1.0). Do not install it — remove it immediately and rotate any exposed credentials.
Malicious code in poc-revshell (PyPI)
What this malware does
poc-revshell 0.1.0 ships a reverse-shell backdoor that fires both at install time and at import time. setup.py registers a custom install cmdclass (PostInstall) that starts a daemon thread executing a routine which opens a TCP socket to 127.0.0.1:4444, dup2s the socket file descriptor onto stdin/stdout/stderr, and execs /bin/sh -i (or cmd.exe on Windows); this runs automatically during pip install. The package's __init__.py contains the same thread-launch at module top level, so every import poc_revshell repeats the handoff. Any local listener on port 4444 at the moment of install or import receives a full interactive shell running under the installing user's identity. The destination is hardcoded loopback, which confines the attack to a co-resident attacker on the installer's host, but the install-time and import-time network-to-shell dataflow is a backdoor by structure, matching the package's self-description as a proof-of-concept that triggers a reverse shell on pip install.
Malicious versions
Indicators of compromise (SHA-256)
Detection & response playbook
Backdoor / remote accessFind it
Search your lockfiles and build artifacts for poc-revshell (version 0.1.0).
If you installed it — respond
poc-revshell establishes remote access, so treat any host that installed it as fully compromised. Isolate the machine, remove the package, rotate all credentials it could reach, and rebuild from a trusted image rather than cleaning in place — a backdoor may have planted additional persistence.
Did it already run?
If poc-revshell was installed, its post-install payload may already have run. Removing the package does not undo that — check outbound connections and credential use from the install window onward.
Frequently asked questions
Campaign
References
Credits
- Amazon Inspector · finder
Detect & block this
O3 blocks poc-revshell-class packages before install and in CI — and if it already ran, its runtime egress monitoring catches the C2 callback and severs the channel.