Detection rules › Sigma

Firewall rule creation (command)

Status
experimental
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 create a firewall rule to allow unauthorized communications.

MITRE ATT&CK coverage

Event coverage

Rule body yaml

title: Firewall rule creation (command)
description: Detects scenarios where an attacker attempts to create a firewall rule to allow unauthorized communications.
references:
- https://research.checkpoint.com/2022/check-point-research-detects-crypto-miner-malware-disguised-as-google-translate-desktop-and-other-legitimate-applications/
- https://thedfirreport.com/2023/10/30/netsupport-intrusion-results-in-domain-compromise/
- https://www.sygnia.co/blog/china-nexus-threat-group-velvet-ant/
tags:
- attack.defense_evasion
- attack.t1562.004
author: mdecrevoisier
status: experimental
logsource:
  product: windows
  category: process_creation
detection: # netsh firewall add portopening TCP 80 "Open Port 80"
  selection_event:
    EventID: 4688
    NewProcessName|endswith: '\netsh.exe' # Full path "C:\Windows\system32\netsh.exe"
    Commandline|contains|all:
      - netsh
      - firewall # covers also advfirewall
      - add
  condition: selection
falsepositives:
- Administrator activity
level: medium

Stages and Predicates

Stage 0: condition

selection

Stage 1: selection_event

selection_event:
  EventID: 4688
  NewProcessName|endswith: '\netsh.exe'
  Commandline|contains|all:
    - netsh
    - firewall
    - add

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
  • add corpus 34 (sigma 26, splunk 4, chronicle 2, kusto 2)
  • firewall corpus 13 (sigma 7, splunk 6)
  • netsh corpus 9 (sigma 9)
NewProcessNameends_with
  • \netsh.exe corpus 28 (sigma 28)