Detection rules › Sigma

Group discovery (command)

Severity
medium
Log source
product windows, category process_creation
Author
mdecrevoisier
Source
github.com/mdecrevoisier/SIGMA-detection-rules

Detects scenarios where an attacker attempts to enumerate local or domain groups via commandline.

MITRE ATT&CK coverage

Event coverage

Rule body yaml

title: Group discovery (command)
description: Detects scenarios where an attacker attempts to enumerate local or domain groups via commandline.
references:
- https://github.com/mdecrevoisier/EVTX-to-MITRE-Attack/tree/master/TA0007-Discovery/T1069-Permission%20Groups%20Discovery
- https://blogs.jpcert.or.jp/en/2016/01/windows-commands-abused-by-attackers.html
- https://github.com/swisskyrepo/PayloadsAllTheThings/blob/master/Methodology%20and%20Resources/Windows%20-%20Privilege%20Escalation.md
- https://attack.mitre.org/software/S0039/
- https://regex101.com/r/S6vTNM/1
tags:
- attack.discovery
- attack.t1069.001 # Permission Groups Discovery: Local Groups 
- attack.t1069.002 # Permission Groups Discovery: Domain Groups 
- attack.t1087.002 # Account Discovery: Domain Account 
author: mdecrevoisier
logsource:
  product: windows
  category: process_creation
detection:
  selection: # Full command example: 'net group "Domain Admins" /domain'
    NewProcessName|endswith:
      - '\net.exe'
      - '\net1.exe'
    CommandLine|contains:
      - group
      - localgroup
  filter:
    CommandLine|contains: add # refers to another use case for groupe membership change creation via commandline
  condition: selection and not filter
falsepositives:
- Pentest
- Administrator activity
level: medium

Stages and Predicates

Stage 0: condition

selection and not filter

Stage 1: selection

selection:
  NewProcessName|endswith:
    - '\net.exe'
    - '\net1.exe'
  CommandLine|contains:
    - group
    - localgroup

Stage 2: not filter

filter:
  CommandLine|contains: add

Exclusions

Top-level NOT(...) conjuncts: predicates this rule actively suppresses.

FieldKindExcluded values
CommandLinematchadd

Indicators

Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.

FieldKindValues
CommandLinematch
  • group corpus 7 (splunk 4, sigma 3)
  • localgroup corpus 2 (sigma 1, kusto 1)
NewProcessNameends_with
  • \net.exe corpus 49 (sigma 49)
  • \net1.exe corpus 47 (sigma 47)