Windows cmd.exe Reads Input from STDIN Using '<' Redirection

Flags cmd.exe invocations with '<' in the command line, indicating stdin/input redirection.

FreeReviewedSigma · Medium · v2
Product
windows
Category
process_creation
Author
frack113, Nasreddine Bencherchali (Nextron Systems) (SigmaHQ), DRL 1.1
Published
2023-03-07
Updated
2026-07-31
title: Windows cmd.exe Reads Input from STDIN Using '<' Redirection
id: 21fe1239-2ebb-4576-9b0b-b96ab7ce40f8
related:
  - id: 00a4bacd-6db4-46d5-9258-a7d5ebff4003
    type: obsolete
  - id: 241e802a-b65e-484f-88cd-c2dc10f9206d
    type: derived
status: test
description: This rule flags Windows process creations where cmd.exe is launched with a command line containing the '<' redirection operator. Such usage can indicate reading data or redirecting input from a file, which may be leveraged to run or influence commands indirectly. It relies on process creation telemetry, specifically the image name/path and the full command line containing '<'.
references:
  - https://github.com/redcanaryco/atomic-red-team/blob/40b77d63808dd4f4eafb83949805636735a1fd15/atomics/T1059.003/T1059.003.md
  - https://web.archive.org/web/20220306121156/https://www.x86matthew.com/view_post?id=ntdll_pipe
  - https://github.com/SigmaHQ/sigma/blob/master/rules/windows/process_creation/proc_creation_win_cmd_stdin_redirect.yml
author: frack113, Nasreddine Bencherchali (Nextron Systems), Huntrule Team
date: 2023-03-07
tags:
  - attack.execution
  - attack.t1059.003
logsource:
  category: process_creation
  product: windows
detection:
  selection_cmd:
    - OriginalFileName: Cmd.Exe
    - Image|endswith: \cmd.exe
  selection_cli:
    CommandLine|contains: <
  condition: all of selection_*
falsepositives:
  - Unknown
level: medium
license: DRL-1.1