Detection rules › Sigma

Password Provided In Command Line Of Net.EXE

Status
test
Severity
medium
Log source
product windows, category process_creation
Author
Tim Shelton (HAWK.IO)
Source
github.com/SigmaHQ/sigma

Detects a when net.exe is called with a password in the command line

MITRE ATT&CK coverage

Event coverage

ProviderEventTitle
SysmonEvent ID 1Process creation

Rule body yaml

title: Password Provided In Command Line Of Net.EXE
id: d4498716-1d52-438f-8084-4a603157d131
status: test
description: Detects a when net.exe is called with a password in the command line
references:
    - Internal Research
author: Tim Shelton (HAWK.IO)
date: 2021-12-09
modified: 2023-02-21
tags:
    - attack.initial-access
    - attack.persistence
    - attack.privilege-escalation
    - attack.lateral-movement
    - attack.stealth
    - attack.t1021.002
    - attack.t1078
logsource:
    category: process_creation
    product: windows
detection:
    selection_img:
        - Image|endswith:
              - '\net.exe'
              - '\net1.exe'
        - OriginalFileName:
              - 'net.exe'
              - 'net1.exe'
    selection_cli:
        CommandLine|contains|all:
            - ' use '
            - ':*\\'
            - '/USER:* *'
    filter_main_empty:
        CommandLine|endswith: ' '
    condition: all of selection_* and not 1 of filter_main_*
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

all of selection_* and not 1 of filter_main_*

Stage 1: selection_img

selection_img:
    - Image|endswith:
          - '\net.exe'
          - '\net1.exe'
    - OriginalFileName:
          - 'net.exe'
          - 'net1.exe'

Stage 2: selection_cli

selection_cli:
    CommandLine|contains|all:
        - ' use '
        - ':*\\'
        - '/USER:* *'

Stage 3: not filter_main_empty

filter_main_empty:
    CommandLine|endswith: ' '

Exclusions

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

FieldKindExcluded values
CommandLineends_with

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
  • use corpus 6 (sigma 6)
  • /USER:* *
  • :*\\
Imageends_with
  • \net.exe corpus 49 (sigma 49)
  • \net1.exe corpus 47 (sigma 47)
OriginalFileNameeq
  • net.exe corpus 28 (sigma 19, elastic 7, splunk 2)
  • net1.exe corpus 44 (sigma 19, splunk 19, elastic 6)