This detection targets adversary post-exploitation behaviors where malicious actors deploy destructive cleaning utilities to sanitize system artifacts and evade forensic analysis within Azure Sentinel. Proactive hunting for this specific YARA signature is essential to identify early-stage cleanup activities that may precede data exfiltration or lateral movement, ensuring the SOC team can intervene before critical evidence is permanently removed.
rule DestructiveTargetCleaningTool3
{
strings:
$S1_CMD_Arg = "/install" fullword
$S2_CMD_Parse= "\"%s\" /install \"%s\"" fullword
$S3_CMD_Builder= "\"%s\" \"%s\" \"%s\" %s" fullword
condition:
all of them
}
This YARA rule can be deployed in the following contexts:
This rule contains 3 string patterns in its detection logic.
Here are 4 specific false positive scenarios for the DestructiveTargetCleaningTool3 detection rule, including suggested filters and exclusions:
Scenario: Automated Windows Update Cleanup via PowerShell
PowerShell.exe scripts. The script invokes the Remove-Item cmdlet with recursive deletion flags, which mimics the behavior of a destructive cleaning tool.C:\Windows\System32\Tasks\Microsoft-Windows-Update-Cleanup where the parent process is TaskScheduler.exe and the command line contains -Command Remove-Item -Recurse.Scenario: Enterprise Antivirus Quarantine Maintenance
falcon-sensor.exe (or equivalent) performing bulk file deletion operations.C:\Program Files\CrowdStrike\*\falcon-sensor.exe) and the action is specifically “Quarantine Cleanup” or “Auto-Delete”.Scenario: Database Transaction Log Truncation
LDF files) for non-critical development databases. This process involves sqlservr.exe calling a specific utility (like dbcc shrinkfile) that aggressively removes unused log