Suspicious Scheduled Task Creation via Masqueraded XML File
A Sigma rule for process creation on Windows, by Swachchhanda Shrawan Poudel, Elastic (idea).
medium 2 ATT&CK techniques 1 program it names
What it looks for
detection:
filter_main_extension_xml:
CommandLine|contains: '.xml'
filter_main_rundll32:
ParentCommandLine|contains|all:
- ':\WINDOWS\Installer\MSI'
- '.tmp,zzzzInvokeManagedCustomActionOutOfProc'
ParentImage|endswith: '\rundll32.exe'
filter_main_system_process:
IntegrityLevel:
- 'System'
- 'S-1-16-16384'
filter_optional_third_party:
ParentImage|endswith:
- ':\ProgramData\OEM\UpgradeTool\CareCenter_*\BUnzip\Setup_msi.exe'
- ':\Program Files\Axis Communications\AXIS Camera Station\SetupActions.exe'
- ':\Program Files\Axis Communications\AXIS Device Manager\AdmSetupActions.exe'
- ':\Program Files (x86)\Zemana\AntiMalware\AntiMalware.exe'
- ':\Program Files\Dell\SupportAssist\pcdrcui.exe'
selection_cli_create:
CommandLine|contains:
- '/create'
- '-create'
selection_cli_xml:
CommandLine|contains:
- '/xml'
- '-xml'
selection_img:
- Image|endswith: '\schtasks.exe'
- OriginalFileName: 'schtasks.exe'
condition: all of selection_* and not 1 of filter_main_* and not 1 of filter_optional_*
The rule’s detection, its selections and fields in order of name. The whole rule, with its references and false positives, is on SigmaHQ, by Swachchhanda Shrawan Poudel, Elastic (idea), under the Detection Rule License 1.1. CmdID evaluates it on a command line alone: a test on what a command line cannot show, such as the parent process or the user, is not met.
None of the everyday examples and documented commands on CmdID’s program pages trips it. To see whether a command line does, paste it into CmdID.