Detection rules › Sigma

Deletion of Volume Shadow Copies via WMI with PowerShell

Status
test
Severity
high
Log source
product windows, category process_creation
Author
Tim Rauch, Elastic (idea)
Source
github.com/SigmaHQ/sigma

Detects deletion of Windows Volume Shadow Copies with PowerShell code and Get-WMIObject. This technique is used by numerous ransomware families such as Sodinokibi/REvil

MITRE ATT&CK coverage

TacticTechniques
ImpactT1490 Inhibit System Recovery

Event coverage

Rule body yaml

title: Deletion of Volume Shadow Copies via WMI with PowerShell
id: 21ff4ca9-f13a-41ad-b828-0077b2af2e40
related:
    - id: e17121b4-ef2a-4418-8a59-12fb1631fa9e
      type: derived
    - id: c1337eb8-921a-4b59-855b-4ba188ddcc42
      type: similar
status: test
description: Detects deletion of Windows Volume Shadow Copies with PowerShell code and Get-WMIObject. This technique is used by numerous ransomware families such as Sodinokibi/REvil
references:
    - https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1490/T1490.md#atomic-test-5---windows---delete-volume-shadow-copies-via-wmi-with-powershell
    - https://www.elastic.co/guide/en/security/current/volume-shadow-copy-deletion-via-powershell.html
author: Tim Rauch, Elastic (idea)
date: 2022-09-20
modified: 2022-12-30
tags:
    - attack.impact
    - attack.t1490
logsource:
    category: process_creation
    product: windows
detection:
    selection_get:
        CommandLine|contains:
            - 'Get-WmiObject'
            - 'gwmi'
            - 'Get-CimInstance'
            - 'gcim'
    selection_shadowcopy:
        CommandLine|contains: 'Win32_ShadowCopy'
    selection_delete:
        CommandLine|contains:
            - '.Delete()'
            - 'Remove-WmiObject'
            - 'rwmi'
            - 'Remove-CimInstance'
            - 'rcim'
    condition: all of selection*
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

all of selection*

Stage 1: selection_get

selection_get:
    CommandLine|contains:
        - 'Get-WmiObject'
        - 'gwmi'
        - 'Get-CimInstance'
        - 'gcim'

Stage 2: selection_shadowcopy

selection_shadowcopy:
    CommandLine|contains: 'Win32_ShadowCopy'

Stage 3: selection_delete

selection_delete:
    CommandLine|contains:
        - '.Delete()'
        - 'Remove-WmiObject'
        - 'rwmi'
        - 'Remove-CimInstance'
        - 'rcim'

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
  • .Delete() corpus 2 (sigma 2)
  • Get-CimInstance
  • Get-WmiObject corpus 6 (splunk 5, sigma 1)
  • Remove-CimInstance
  • Remove-WmiObject
  • Win32_ShadowCopy
  • gcim
  • gwmi
  • rcim
  • rwmi