This rule targets the presence of the “theWRAPbyTronDoc” YARA signature, which indicates the execution or persistence of a specific low-severity document-based payload or macro. Proactively hunting for this indicator allows the SOC team to identify early-stage footholds or benign-looking artifacts that adversaries may use to establish initial access before escalating privileges in the Azure Sentinel environment.
rule theWRAPbyTronDoc
{
meta:
author="malware-lu"
strings:
$a0 = { 55 8B EC 83 C4 F0 53 56 57 33 C0 89 45 F0 B8 48 D2 4B 00 E8 BC 87 F4 FF BB 04 0B 4D 00 33 C0 55 68 E8 D5 4B 00 64 FF 30 64 89 20 E8 9C F4 FF FF E8 F7 FB FF FF 6A 40 8D 55 F0 A1 F0 ED 4B 00 8B 00 E8 42 2E F7 FF 8B 4D F0 B2 01 A1 F4 C2 40 00 E8 F7 20 F5 FF 8B F0 B2 01 A1 B4 C3 40 00 E8 F1 5B F4 FF 89 03 33 D2 8B 03 E8 42 1E F5 FF 66 B9 02 00 BA FC FF FF FF 8B C6 8B 38 FF 57 0C BA B8 A7 4D 00 B9 04 00 00 00 8B C6 8B 38 FF 57 04 83 3D B8 A7 4D 00 00 0F 84 5E 01 00 00 8B 15 B8 A7 4D 00 83 C2 04 F7 DA 66 B9 02 00 8B C6 8B 38 FF 57 0C 8B 0D B8 A7 4D 00 8B D6 8B 03 E8 2B 1F F5 FF 8B C6 E8 B4 5B F4 FF 33 D2 8B 03 E8 DF 1D F5 FF BA F0 44 4E 00 B9 01 00 00 00 8B 03 8B 30 FF 56 04 80 3D F0 44 4E 00 0A 75 3F BA B8 A7 4D 00 B9 04 00 00 00 8B 03 8B 30 FF 56 04 8B 15 B8 A7 }
condition:
$a0 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 Git for Windows or a similar version control client that bundles a custom or modified Tron (The Tron Project) wrapper script or documentation generator to package release notes. The YARA rule may match the specific byte sequence of the theWRAPbyTronDoc signature within the generated .doc or .pdf metadata.
C:\Users\*\AppData\Local\Temp\git-*, C:\projects\*\docs\) or exclude processes named git.exe, code.exe (VS Code), or cmd.exe when the file extension is .doc or .pdf and the path contains release or docs.Scenario: An IT administrator runs a scheduled PowerShell job using PowerShell Direct or a custom script to convert legacy Word documents to PDF using LibreOffice or Microsoft Word COM objects. The conversion process creates a temporary file that retains the original document’s embedded metadata or specific header/footer strings that match the theWRAPbyTronDoc YARA pattern.
%TEMP% or %LOCALAPPDATA% directories that are created by soffice.exe (LibreOffice) or WINWORD.EXE (Word) and are less than 5 minutes old. Additionally, exclude paths containing ~$ (Word temporary lock files) or libreoffice in the path.Scenario: A security team performs a Vulnerability Assessment using tools like Nessus or Qualys that generate report packages. These tools sometimes embed custom document templates or wrapper scripts (named theWRAPbyTronDoc or similar) to standardize report