Detections · ex/ar/pack · BIOC
Cortex XDR / XSIAM BIOC
A3. SQL Server spawns a shell through xp_cmdshell
SQL Server toolkit seen with ARTEX operators: xp_cmdshell starts cmd or PowerShell to drop a Gh0st RAT and a miner. Adapted from ThreatDefence rules (MIT licence).
Experimental rule, translated automatically from the XQL query: one BIOC per event type. Create each BIOC disabled, test it, then enable it. DRL 1.1 license.
Two ways to add it
- By hand: Detection Rules → BIOC → Add BIOC, XQL mode, paste the query below (one per BIOC), then set the name, type, severity and ATT&CK shown.
- By API: download the API file and push it with push_bioc.py (Standard API key, BIOCs created disabled). The Import Rules dialog only accepts files exported by Cortex: this file is not meant for it.
dataset = xdr_data
| filter event_type = ENUM.PROCESS and (actor_process_image_name = "sqlservr.exe" and action_process_image_name in ("cmd.exe", "powershell.exe", "pwsh.exe", "certutil.exe", "bitsadmin.exe"))
Type EXECUTIONSeverity SEV_040_HIGHPROCESS_EXECUTION_EVENT
T1059.003 - Command and Scripting Interpreter: Windows Command Shell · T1505.001 - Server Software Component: SQL Stored Procedures