Detection rules › Sigma

Enumeration for Credentials in Registry

Status
test
Severity
medium
Log source
product windows, category process_creation
Author
frack113
Source
github.com/SigmaHQ/sigma

Adversaries may search the Registry on compromised systems for insecurely stored credentials. The Windows Registry stores configuration information that can be used by the system or other programs. Adversaries may query the Registry looking for credentials and passwords that have been stored for use by other programs or services

MITRE ATT&CK coverage

Event coverage

Rule body yaml

title: Enumeration for Credentials in Registry
id: e0b0c2ab-3d52-46d9-8cb7-049dc775fbd1
status: test
description: |
    Adversaries may search the Registry on compromised systems for insecurely stored credentials.
    The Windows Registry stores configuration information that can be used by the system or other programs.
    Adversaries may query the Registry looking for credentials and passwords that have been stored for use by other programs or services
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1552.002/T1552.002.md
author: frack113
date: 2021-12-20
modified: 2022-12-25
tags:
    - attack.credential-access
    - attack.t1552.002
logsource:
    category: process_creation
    product: windows
detection:
    reg:
        Image|endswith: '\reg.exe'
        CommandLine|contains|all:
            - ' query '
            - '/t '
            - 'REG_SZ'
            - '/s'
    hive:
        - CommandLine|contains|all:
              - '/f '
              - 'HKLM'
        - CommandLine|contains|all:
              - '/f '
              - 'HKCU'
        - CommandLine|contains: 'HKCU\Software\SimonTatham\PuTTY\Sessions'
    condition: reg and hive
falsepositives:
    - Unknown
level: medium

Stages and Predicates

Stage 0: condition

reg and hive

Stage 1: reg

reg:
    Image|endswith: '\reg.exe'
    CommandLine|contains|all:
        - ' query '
        - '/t '
        - 'REG_SZ'
        - '/s'

Stage 2: hive

hive:
    - CommandLine|contains|all:
          - '/f '
          - 'HKLM'
    - CommandLine|contains|all:
          - '/f '
          - 'HKCU'
    - CommandLine|contains: 'HKCU\Software\SimonTatham\PuTTY\Sessions'

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
  • query corpus 4 (splunk 3, sigma 1)
  • /f corpus 3 (sigma 3)
  • /s corpus 8 (sigma 6, splunk 2)
  • /t corpus 2 (sigma 2)
  • HKCU
  • HKCU\Software\SimonTatham\PuTTY\Sessions
  • HKLM corpus 4 (sigma 3, kusto 1)
  • REG_SZ
Imageends_with
  • \reg.exe corpus 58 (sigma 58)