MAL-2026-20955: Malicious code in reuquests (PyPI)
reuquests is a typosquat of requests that copies requests 2.28.2 and installs a top-level 'requests' module, so the payload runs whenever 'requests' is imported (including by other libraries), not at install time. requests/init.py adds dwarfvoice(), called at module level: unless ~/.nope exists (a run-once marker created after a successful upload), it silences stdout/stderr for the rest of the process, collects ~/.ssh/idrsa, ~/.ssh/knownhosts, ~/.bashhistory, the login name, directory listings of the working and home directories and the contents of every file in the working directory, gzips them to res.gz (left in the working directory) and POSTs the data to hxxp://azazell[.]pythonanywhere[.]com/log. The package has been removed from PyPI; this analysis is based on the archived source distribution of 2.28.2 (DataDog malicious-software-packages-dataset). It is part of a small 'Albert Xor' campaign from 2023-03-20 with the flask typosquat flsak, which uses the same PythonAnywhere host.
Affected Software
Event History
Frequently Asked Questions
When does the malicious behavior execute?
It executes when the top-level requests module is imported, including when another library imports requests. It does not wait for package installation.
Which environments are exposed to execution?
Any environment where reuquests is installed and requests is imported is exposed. Because reuquests installs a top-level requests module, imports intended for the legitimate requests package can trigger it.
What information can be collected?
The code collects the user's SSH private key and known-hosts files, Bash history, login name, listings of the working and home directories, and the contents of every file in the working directory. It gzips the collected data into res.gz before uploading it.
What indicators can help determine whether it ran?
Look for a res.gz file in the working directory, a ~/.nope marker file, and outbound POST traffic to azazell.pythonanywhere.com/log. The ~/.nope file is created after a successful upload and is used to prevent another collection attempt.