Detection rules › Sigma

Suspicious Persistence Via VMwareToolBoxCmd.EXE VM State Change Script

Status
test
Severity
high
Log source
product windows, category process_creation
Author
Nasreddine Bencherchali (Nextron Systems)
Source
github.com/SigmaHQ/sigma

Detects execution of the "VMwareToolBoxCmd.exe" with the "script" and "set" flag to setup a specific script that's located in a potentially suspicious location to run for a specific VM state

MITRE ATT&CK coverage

Event coverage

ProviderEventTitle
SysmonEvent ID 1Process creation

Rule body yaml

title: Suspicious Persistence Via VMwareToolBoxCmd.EXE VM State Change Script
id: 236d8e89-ed95-4789-a982-36f4643738ba
related:
    - id: 7aa4e81a-a65c-4e10-9f81-b200eb229d7d
      type: derived
status: test
description: Detects execution of the "VMwareToolBoxCmd.exe" with the "script" and "set" flag to setup a specific script that's located in a potentially suspicious location to run for a specific VM state
references:
    - https://bohops.com/2021/10/08/analyzing-and-detecting-a-vmtools-persistence-technique/
author: Nasreddine Bencherchali (Nextron Systems)
date: 2023-06-14
tags:
    - attack.execution
    - attack.persistence
    - attack.t1059
logsource:
    category: process_creation
    product: windows
detection:
    selection_bin_img:
        - Image|endswith: '\VMwareToolBoxCmd.exe'
        - OriginalFileName: 'toolbox-cmd.exe'
    selection_bin_cli:
        CommandLine|contains|all:
            - ' script '
            - ' set '
    selection_susp_paths:
        CommandLine|contains:
            - ':\PerfLogs\'
            - ':\Temp\'
            - ':\Windows\System32\Tasks\'
            - ':\Windows\Tasks\'
            - ':\Windows\Temp\'
            - '\AppData\Local\Temp'
    condition: all of selection_*
falsepositives:
    - Unknown
level: high

Stages and Predicates

Stage 0: condition

all of selection_*

Stage 1: selection_bin_img

selection_bin_img:
    - Image|endswith: '\VMwareToolBoxCmd.exe'
    - OriginalFileName: 'toolbox-cmd.exe'

Stage 2: selection_bin_cli

selection_bin_cli:
    CommandLine|contains|all:
        - ' script '
        - ' set '

Stage 3: selection_susp_paths

selection_susp_paths:
    CommandLine|contains:
        - ':\PerfLogs\'
        - ':\Temp\'
        - ':\Windows\System32\Tasks\'
        - ':\Windows\Tasks\'
        - ':\Windows\Temp\'
        - '\AppData\Local\Temp'

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
  • script corpus 2 (sigma 2)
  • set corpus 4 (sigma 4)
  • :\PerfLogs\ corpus 11 (sigma 11)
  • :\Temp\ corpus 14 (sigma 14)
  • :\Windows\System32\Tasks\ corpus 4 (sigma 4)
  • :\Windows\Tasks\ corpus 6 (sigma 6)
  • :\Windows\Temp\ corpus 16 (sigma 16)
  • \AppData\Local\Temp corpus 8 (sigma 8)
Imageends_with
  • \VMwareToolBoxCmd.exe corpus 2 (sigma 2)
OriginalFileNameeq
  • toolbox-cmd.exe corpus 2 (sigma 2)