Detection rules › Sigma

CobaltStrike Load by Rundll32

Status
test
Severity
high
Log source
category process_creation, product windows
Author
Wojciech Lesicki
Source
github.com/SigmaHQ/sigma

Rundll32 can be use by Cobalt Strike with StartW function to load DLLs from the command line.

MITRE ATT&CK coverage

Telemetry coverage

ProviderRecord / event type
SysmonEvent ID 1: Process creation

Rule body

title: CobaltStrike Load by Rundll32
id: ae9c6a7c-9521-42a6-915e-5aaa8689d529
status: test
description: Rundll32 can be use by Cobalt Strike with StartW function to load DLLs from the command line.
references:
    - https://www.cobaltstrike.com/help-windows-executable
    - https://redcanary.com/threat-detection-report/
    - https://thedfirreport.com/2020/10/18/ryuk-in-5-hours/
author: Wojciech Lesicki
date: 2021-06-01
modified: 2022-09-16
tags:
    - attack.stealth
    - attack.t1218.011
logsource:
    category: process_creation
    product: windows
detection:
    selection_rundll:
        - Image|endswith: '\rundll32.exe'
        - OriginalFileName: RUNDLL32.EXE
        - CommandLine|contains:
              - 'rundll32.exe'
              - 'rundll32 '
    selection_params:
        CommandLine|contains: '.dll'
        CommandLine|endswith:
            - ' StartW'
            - ',StartW'
    condition: all of selection*
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

all of selection*

Stage 1: selection_rundll

selection_rundll:
    - Image|endswith: '\rundll32.exe'
    - OriginalFileName: RUNDLL32.EXE
    - CommandLine|contains:
          - 'rundll32.exe'
          - 'rundll32 '

Stage 2: selection_params

selection_params:
    CommandLine|contains: '.dll'
    CommandLine|endswith:
        - ' StartW'
        - ',StartW'

Indicators

These rows show field, operator, and value matches.

FieldKindValuesSearch
CommandLineends_with
  • StartW
  • ,StartW
field:"CommandLine" kind:ends_with
CommandLinematch
  • .dll corpus 16 (sigma 16)
  • rundll32 corpus 2 (sigma 2)
  • rundll32.exe corpus 8 (sigma 8)
field:"CommandLine" kind:match
Imageends_with
  • \rundll32.exe corpus 94 (sigma 94)
field:"Image" kind:ends_with value:"\rundll32.exe"
OriginalFileNameeq
  • RUNDLL32.EXE corpus 78 (sigma 35, elastic 22, splunk 21)
field:"OriginalFileName" kind:eq value:"RUNDLL32.EXE"