Windows PowerShell via sqltoolsps.exe (sqltoolsps.exe child process exclusion)
Flags suspicious sqltoolsps.exe executions that may launch PowerShell, excluding cases where smss.exe spawned the utility.
FreeUnreviewedSigmamediumv1
windows-powershell-via-sqltoolsps-exe-sqltoolsps-exe-child-process-exclusion-a746c9b8
title: Windows PowerShell via sqltoolsps.exe (sqltoolsps.exe child process exclusion)
id: 62a498b7-8604-40b1-9a73-adecc9167146
status: test
description: This rule identifies executions of sqltoolsps.exe where the process is started directly and is not created by smss.exe. Attackers can use sqltoolsps.exe as a PowerShell execution path, which may evade protections that depend on PowerShell script block logging. It relies on Windows process creation telemetry, matching the executable path and parent process relationships to determine the execution context.
references:
- https://github.com/LOLBAS-Project/LOLBAS/blob/8283d8d91552213ded165fd36deb6cb9534cb443/yml/OtherMSBinaries/Sqltoolsps.yml
- https://twitter.com/pabraeken/status/993298228840992768
- https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_mssql_sqltoolsps_susp_execution.yml
author: Agro (@agro_sev) oscd.communitly, Huntrule Team
date: 2020-10-13
modified: 2022-02-25
tags:
- attack.execution
- attack.stealth
- attack.t1059.001
- attack.t1127
logsource:
category: process_creation
product: windows
detection:
selection:
- Image|endswith: \sqltoolsps.exe
- ParentImage|endswith: \sqltoolsps.exe
- OriginalFileName: \sqltoolsps.exe
filter:
ParentImage|endswith: \smss.exe
condition: selection and not filter
falsepositives:
- Direct PS command execution through SQLToolsPS.exe is uncommon, childprocess sqltoolsps.exe spawned by smss.exe is a legitimate action.
level: medium
license: DRL-1.1
related:
- id: a746c9b8-a2fb-4ee5-a428-92bee9e99060
type: derived
What it detects
This rule identifies executions of sqltoolsps.exe where the process is started directly and is not created by smss.exe. Attackers can use sqltoolsps.exe as a PowerShell execution path, which may evade protections that depend on PowerShell script block logging. It relies on Windows process creation telemetry, matching the executable path and parent process relationships to determine the execution context.
Known false positives
- Direct PS command execution through SQLToolsPS.exe is uncommon, childprocess sqltoolsps.exe spawned by smss.exe is a legitimate action.
Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.