Detection rules › Sigma

Suspicious Remote Logon with Explicit Credentials

Status
test
Severity
medium
Log source
product windows, service security
Author
oscd.community, Teymur Kheirkhabarov @HeirhabarovT, Zach Stanford @svch0st, Tim Shelton
Source
github.com/SigmaHQ/sigma

Detects suspicious processes logging on with explicit credentials

MITRE ATT&CK coverage

TacticTechniques
Initial AccessT1078 Valid Accounts
PersistenceT1078 Valid Accounts
Privilege EscalationT1078 Valid Accounts
StealthT1078 Valid Accounts

Event coverage

Rule body yaml

title: Suspicious Remote Logon with Explicit Credentials
id: 941e5c45-cda7-4864-8cea-bbb7458d194a
status: test
description: Detects suspicious processes logging on with explicit credentials
references:
    - https://drive.google.com/file/d/1lKya3_mLnR3UQuCoiYruO3qgu052_iS_/view
author: oscd.community, Teymur Kheirkhabarov @HeirhabarovT, Zach Stanford @svch0st, Tim Shelton
date: 2020-10-05
modified: 2022-08-03
tags:
    - attack.privilege-escalation
    - attack.persistence
    - attack.initial-access
    - attack.stealth
    - attack.t1078
    - attack.lateral-movement
logsource:
    product: windows
    service: security
detection:
    selection:
        EventID: 4648
        ProcessName|endswith:
            - '\cmd.exe'
            - '\powershell.exe'
            - '\pwsh.exe'
            - '\winrs.exe'
            - '\wmic.exe'
            - '\net.exe'
            - '\net1.exe'
            - '\reg.exe'
    filter1:
        TargetServerName: 'localhost'
    filter2:
        SubjectUserName|endswith: '$'
        TargetUserName|endswith: '$'
    condition: selection and not 1 of filter*
falsepositives:
    - Administrators that use the RunAS command or scheduled tasks
level: medium

Stages and Predicates

Stage 0: condition

selection and not 1 of filter*

Stage 1: selection

selection:
    EventID: 4648
    ProcessName|endswith:
        - '\cmd.exe'
        - '\powershell.exe'
        - '\pwsh.exe'
        - '\winrs.exe'
        - '\wmic.exe'
        - '\net.exe'
        - '\net1.exe'
        - '\reg.exe'

Stage 2: not filter*

filter1:
    TargetServerName: 'localhost'
filter2:
    SubjectUserName|endswith: '$'
    TargetUserName|endswith: '$'

Exclusions

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

FieldKindExcluded values
SubjectUserNameends_with$
TargetUserNameends_with$
TargetServerNameeqlocalhost

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
ProcessNameends_with
  • \cmd.exe
  • \net.exe
  • \net1.exe
  • \powershell.exe
  • \pwsh.exe
  • \reg.exe
  • \winrs.exe
  • \wmic.exe