This detection identifies potential shell script modifications that may indicate an adversary establishing persistence or executing malicious payloads within the environment. Proactive hunting for this behavior in Azure Sentinel is essential to uncover subtle post-compromise activities that might evade standard alerting thresholds due to their low severity classification.
rule ShellModify01pll621
{
meta:
author="malware-lu"
strings:
$a0 = { 55 8B EC 6A FF 68 98 66 41 00 68 3C 3D 41 00 64 A1 00 00 00 00 }
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.
Here are 4 specific false positive scenarios for the ShellModify01pll621 detection rule, including suggested filters and exclusions:
Scenario: Scheduled PowerShell Script Execution by System Account
.ps1 script via Task Scheduler under the NT SYSTEM account to update inventory logs. This triggers the rule as it modifies shell objects or executes code in memory.Process Image Path: C:\Windows\System32\Tasks\* (or specific task name)User Account: NT AUTHORITY\SYSTEMsvchost.exe or TaskSchedulerService running as SYSTEM.Scenario: Legitimate Admin Deployment via SCCM/Intune
ccmexec.exe spawning powershell.exe.Process Image Name: ccmexec.exe, IntuneManagementExtension.exeParent Process Image Name: msiexec.exe, ccmsetup.exeScenario: Automated Backup and Reporting Tools