Windows Process Creation: Recon Data Export via Command Prompt Redirection
Alerts when recon-related Windows utilities are launched with command-line output redirected to temp locations.
FreeUnreviewedSigmamediumv1
windows-process-creation-recon-data-export-via-command-prompt-redirection-aa2efee7
title: "Windows Process Creation: Recon Data Export via Command Prompt Redirection"
id: 030864a4-9b3c-4a41-8e4a-7789488706f7
related:
- id: 8e0bb260-d4b2-4fff-bb8d-3f82118e6892
type: similar
- id: aa2efee7-34dd-446e-8a37-40790a66efd7
type: derived
status: test
description: This rule flags Windows process creation where the spawned executable matches common data-recon utilities (tree.com, WMIC.exe, doskey.exe, sc.exe) and the parent command line includes output redirection to %TEMP% or %TMP%. Attackers often export or stage collected information for later use, and leveraging command-line redirection helps conceal where output is written and facilitates automated collection. Telemetry relies on process creation events including the image path, original filename, and the parent command line contents.
references:
- https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1119/T1119.md
- https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_susp_recon.yml
author: frack113, Huntrule Team
date: 2021-07-30
modified: 2022-09-13
tags:
- attack.collection
- attack.t1119
logsource:
product: windows
category: process_creation
detection:
selection_image:
- Image|endswith:
- \tree.com
- \WMIC.exe
- \doskey.exe
- \sc.exe
- OriginalFileName:
- wmic.exe
- DOSKEY.EXE
- sc.exe
selection_redirect:
ParentCommandLine|contains:
- " > %TEMP%\\"
- " > %TMP%\\"
condition: all of selection*
falsepositives:
- Unknown
level: medium
license: DRL-1.1
What it detects
This rule flags Windows process creation where the spawned executable matches common data-recon utilities (tree.com, WMIC.exe, doskey.exe, sc.exe) and the parent command line includes output redirection to %TEMP% or %TMP%. Attackers often export or stage collected information for later use, and leveraging command-line redirection helps conceal where output is written and facilitates automated collection. Telemetry relies on process creation events including the image path, original filename, and the parent command line contents.
Known false positives
- Unknown
Detection content is published as a reviewed draft. Tune thresholds and exclusions against your own telemetry before enabling this rule for alerting.