Rundll32 Execution With Uncommon DLL Extension

Detects the execution of rundll32 with a command line that doesn't contain a common extension

Sigma rule (View on GitHub)

 1title: Rundll32 Execution With Uncommon DLL Extension
 2id: c3a99af4-35a9-4668-879e-c09aeb4f2bdf
 3status: test
 4description: Detects the execution of rundll32 with a command line that doesn't contain a common extension
 5references:
 6    - https://twitter.com/mrd0x/status/1481630810495139841?s=12
 7author: Tim Shelton, Florian Roth (Nextron Systems), Yassine Oukessou
 8date: 2022-01-13
 9modified: 2026-10-13
10tags:
11    - attack.stealth
12    - attack.t1218.011
13logsource:
14    category: process_creation
15    product: windows
16detection:
17    selection:
18        - Image|endswith: '\rundll32.exe'
19        - OriginalFileName: 'RUNDLL32.EXE'
20    filter_main_null:
21        CommandLine: null
22    filter_main_empty:
23        CommandLine: ''
24    filter_main_known_extension:
25        - CommandLine|contains:
26              # Note: This aims to cover: single and double quotes in addition to spaces and comma "," usage.
27              - '.cpl '
28              - '.cpl,'
29              - '.cpl"'
30              - ".cpl'"
31              - '.dll '
32              - '.dll,'
33              - '.dll"'
34              - ".dll'"
35              - '.inf '
36              - '.inf,'
37              - '.inf"'
38              - ".inf'"
39        - CommandLine|endswith:
40              # Note: This aims to cover: single and double quotes in addition to spaces and comma "," usage.
41              - '.cpl'
42              - '.dll'
43              - '.inf'
44    filter_main_localserver:
45        CommandLine|contains: ' -localserver '
46    filter_main_zzzzInvokeManagedCustomActionOutOfProc:
47        ParentImage|endswith: '\msiexec.exe'
48        CommandLine|contains|all:
49            - ':\Windows\Installer\'
50            - '.tmp'
51            - 'zzzzInvokeManagedCustomActionOutOfProc'
52    filter_main_streamci:
53        # Windows streaming-device class installer, run by svchost (DeviceInstall) during driver setup
54        # e.g. rundll32.exe streamci,StreamingDeviceSetup {eeab7790-c514-11d1-b42b-00805fc1270e},asyncmac,{...}
55        Image: 'C:\Windows\System32\rundll32.exe'
56        ParentImage: 'C:\Windows\System32\svchost.exe'
57        CommandLine|contains: ' streamci,StreamingDeviceSetup {'
58    filter_optional_EdgeUpdate:
59        ParentCommandLine|contains|all:
60            - ':\Users\'
61            - '\AppData\Local\Microsoft\EdgeUpdate\Install\{'
62            - '\EDGEMITMP_'
63            - '.tmp\setup.exe'
64            - '--install-archive='
65            - '--previous-version='
66            - '--msedgewebview --verbose-logging --do-not-launch-msedge --user-level'
67    condition: selection and not 1 of filter_main_* and not 1 of filter_optional_*
68falsepositives:
69    - Unknown
70level: medium
71regression_tests_path: regression_data/rules/windows/process_creation/proc_creation_win_rundll32_uncommon_dll_extension/info.yml

References

Related rules

to-top