Malicious code in hello-bat-fwi9 (PyPI)
- MAL-2026-18735
Description
Show the whole descriptionHide the whole description
The wheel ships a 2.5MB obfuscated hello.bat that is invoked by the package's advertised hello() function and by the hello-bat-fwi9 console_script. On Windows the batch launches a headless conhost, extracts a hidden CPython runtime to %LOCALAPPDATA%\Programs\Python3_iFvHdqxj via tar.exe -xf python.zip, and decodes base64 fragments to write a sitecustomize.py into that runtime's site directory so every subsequent interpreter start re-executes the payload. Decoded fragments assemble a Python script that calls the Task Scheduler COM API (Schedule.Service / RegisterTaskDefinition) with SYSTEM/S4U logon fallbacks to install persistent scheduled-task execution, and contain CLR-hosting strings. The batch contains multi-megabyte base64 blobs (one ~1.8MB), scrambled environment-variable names, and set/call goto control-flow obfuscation. The README and METADATA explicitly claim the file is a readable 5-line hello.bat with no persistence, scheduled task, network access, or hidden execution — the shipped artifact performs the opposite, making the declared purpose a cover story. Running the advertised API on Windows yields full-host code execution and persistent compromise of the installer's machine. The package delivers an obfuscated .bat file delivering a RAT, with the help of its own Python runtime and PTH files. The code requires manually triggering the malicious action. This is most likely a continuation of the campaign 2026-11-filipt. --- Category: MALICIOUS - The campaign has clearly malicious intent, like infostealers. Campaign: 2026-11-hello-bat-fwi9 Reasons (based on the campaign): - obfuscation - rat - abuses-pth - malware
Text from the OSV record.
Recommendation
Remove the package and rotate any secret the machine that installed it could reach. There is no version to update to.
Affected
hello-bat-fwi9PyPI
No versions listed
Timeline
- Published
Related news
No article from the followed outlets names this vulnerability.