This rule identifies executable files packed with the UPX compressor, a technique frequently employed by adversaries to reduce binary size and evade signature-based detection. Proactively hunting for these packed binaries in Azure Sentinel helps uncover stealthy payloads that may be executing on endpoints or within cloud workloads, ensuring that obfuscated malware is not overlooked during routine monitoring.
rule UPXV194MarkusOberhumerLaszloMolnarJohnReiser
{
meta:
author="malware-lu"
strings:
$a0 = { FF D5 80 A7 [5] 58 50 54 50 53 57 FF D5 58 61 8D 44 24 ?? 6A 00 39 C4 75 FA 83 EC 80 E9 }
condition:
$a0
}
This YARA rule can be deployed in the following contexts:
This rule contains 1 string patterns in its detection logic.
chrome.exe in Google Chrome, code.exe in VS Code, or node.exe in Node.js distributions). Many open-source and commercial applications use UPX to reduce binary size, causing the YARA signature to match the process image or loaded modules.
msiexec.exe, setup.exe) or where the executable path resides in standard application directories like C:\Program Files\Google\Chrome\ or C:\Users\<User>\AppData\Local\Programs\.7z.exe in 7-Zip, winrar.exe in WinRAR, or custom PowerShell wrappers that invoke UPX-compressed helper binaries for log rotation or disk cleanup). These are often triggered by Task Scheduler or cron-like services.
schtasks.exe or taskeng.exe where the command line contains specific keywords like cleanup, compress, or backup, or exclude known utility paths such as C:\Program Files\7-Zip\ or C:\Program Files\WinRAR\.gdb.exe in GDB, lldb.exe in LLDB, or custom C/C++ test harnesses compiled with UPX optimization). This is common in CI/CD pipelines or local dev workstations.
Developer or CI-Service group membership, or exclude paths containing build, dist, `