This rule detects the presence of PE bundle executables, which adversaries often use to pack or obfuscate malicious payloads to evade static analysis and signature-based detection. Proactively hunting for these artifacts in Azure Sentinel helps identify potentially hidden or modified binaries that may be executing on endpoints, allowing the SOC to investigate suspicious processes before they trigger more advanced post-exploitation behaviors.
rule PEBundle_v02_v20x_additional: PEiD
{
strings:
$a = { 9C 60 E8 02 ?? ?? ?? 33 C0 8B C4 83 C0 04 93 8B E3 8B 5B FC 81 EB ?? ?? 40 ?? 87 DD 01 AD ?? ?? ?? ?? 01 AD }
condition:
$a at pe.entry_point
}
This YARA rule can be deployed in the following contexts:
This rule contains 1 string patterns in its detection logic.
Scenario: A developer or DevOps engineer uses Visual Studio or Visual Studio Code to build a C++ application that includes the PEBundle library (e.g., for creating self-extracting archives or embedded resources). The compiler or linker generates a binary containing the specific PEBundle signature strings or structural markers, causing the YARA rule to match the compiled .exe or .dll file in the build output directory.
C:\Users\*\AppData\Local\Temp\*, C:\Projects\*\build\*, C:\src\*\bin\*) or files with extensions .obj, .lib, and .pdb that are intermediate build artifacts. Alternatively, exclude processes like MSBuild.exe, cl.exe, or link.exe if the rule triggers on the process image rather than the file.Scenario: An IT administrator runs a scheduled task using 7-Zip or WinRAR to create self-extracting archives (SFX) for software distribution. These SFX executables often embed a PE header and may use bundling techniques that mimic the PEBundle structure, especially if the archive tool uses a custom stub that shares similar memory layout or string patterns.
.sfx extension or files created by known archiving tools (7z.exe, WinRAR.exe) in network share locations (e.g., \\fileserver\software\*, C:\Deploy\*). If the rule triggers on the process, exclude 7z.exe or WinRAR.exe when the parent process is a scheduled task service (Svchost.exe or Taskeng.exe).Scenario: A security team deploys a