Detection rules › Sigma

Root Certificate Installed - PowerShell

Status
test
Severity
medium
Log source
product windows, category ps_script
Author
oscd.community, @redcanary, Zach Stanford @svch0st
Source
github.com/SigmaHQ/sigma

Adversaries may install a root certificate on a compromised system to avoid warnings when connecting to adversary controlled web servers.

MITRE ATT&CK coverage

Event coverage

Rule body yaml

title: Root Certificate Installed - PowerShell
id: 42821614-9264-4761-acfc-5772c3286f76
status: test
description: Adversaries may install a root certificate on a compromised system to avoid warnings when connecting to adversary controlled web servers.
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1553.004/T1553.004.md
author: 'oscd.community, @redcanary, Zach Stanford @svch0st'
date: 2020-10-10
modified: 2022-12-02
tags:
    - attack.defense-impairment
    - attack.t1553.004
logsource:
    product: windows
    category: ps_script
    definition: 'Requirements: Script Block Logging must be enabled'
detection:
    selection1:
        ScriptBlockText|contains|all:
            - 'Move-Item'
            - 'Cert:\LocalMachine\Root'
    selection2:
        ScriptBlockText|contains|all:
            - 'Import-Certificate'
            - 'Cert:\LocalMachine\Root'
    condition: 1 of selection*
falsepositives:
    - Help Desk or IT may need to manually add a corporate Root CA on occasion. Need to test if GPO push doesn't trigger FP
level: medium

Stages and Predicates

Stage 0: condition

1 of selection*

Stage 1: selection1

selection1:
    ScriptBlockText|contains|all:
        - 'Move-Item'
        - 'Cert:\LocalMachine\Root'

Stage 2: selection2

selection2:
    ScriptBlockText|contains|all:
        - 'Import-Certificate'
        - 'Cert:\LocalMachine\Root'

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
ScriptBlockTextmatch
  • Cert:\LocalMachine\Root
  • Import-Certificate
  • Move-Item