HackTool - CrackMapExec Execution Patterns

Detects various execution patterns of the CrackMapExec pentesting framework

Sigma rule (View on GitHub)

 1title: HackTool - CrackMapExec Execution Patterns
 2id: 058f4380-962d-40a5-afce-50207d36d7e2
 3status: stable
 4description: Detects various execution patterns of the CrackMapExec pentesting framework
 5references:
 6    - https://github.com/byt3bl33d3r/CrackMapExec
 7author: Thomas Patzke
 8date: 2020/05/22
 9modified: 2023/11/06
10tags:
11    - attack.execution
12    - attack.t1047
13    - attack.t1053
14    - attack.t1059.003
15    - attack.t1059.001
16    - attack.s0106
17logsource:
18    category: process_creation
19    product: windows
20detection:
21    selection:
22        CommandLine|contains:
23            # cme/protocols/smb/wmiexec.py (generalized execute_remote and execute_fileless)
24            - 'cmd.exe /Q /c * 1> \\\\*\\*\\* 2>&1'
25            # cme/protocols/smb/atexec.py:109 (fileless output via share)
26            - 'cmd.exe /C * > \\\\*\\*\\* 2>&1'
27            # cme/protocols/smb/atexec.py:111 (fileless output via share)
28            - 'cmd.exe /C * > *\\Temp\\* 2>&1'
29            # https://github.com/byt3bl33d3r/CrackMapExec/blob/d8c50c8cbaf36c29329078662473f75e440978d2/cme/helpers/powershell.py#L136 (PowerShell execution with obfuscation)
30            - 'powershell.exe -exec bypass -noni -nop -w 1 -C "'
31            # https://github.com/byt3bl33d3r/CrackMapExec/blob/d8c50c8cbaf36c29329078662473f75e440978d2/cme/helpers/powershell.py#L160 (PowerShell execution without obfuscation)
32            - 'powershell.exe -noni -nop -w 1 -enc '
33    condition: selection
34falsepositives:
35    - Unknown
36level: high

References

Related rules

to-top