Suspicious Execute Invoke-command on Remote Host (via ps_script)
This rule detects threat actors may use Valid Accounts to interact with remote systems using Windows Remote Management (WinRM). The adversary may then perform actions as the logged-on user.
SigmamediumWindowsv1
sigma
suspicious-execute-invoke-command-on-remote-host-via-ps-script
title: Suspicious Execute Invoke-command on Remote Host (via ps_script)
id: 24498a00-a3b3-590b-88ac-d2e56f0a51e9
status: stable
description: This rule detects threat actors may use Valid Accounts to interact with remote systems using Windows Remote Management (WinRM). The adversary may then perform actions as the logged-on user.
references:
- https://attack.mitre.org/techniques/T1021/006/
- https://github.com/redcanaryco/atomic-red-team/blob/f339e7da7d05f6057fdfcdd3742bfcf365fee2a9/atomics/T1021.006/T1021.006.md#atomic-test-2---invoke-command
- https://learn.microsoft.com/en-us/powershell/module/microsoft.powershell.core/invoke-command?view=powershell-7.4
author: Huntrule Team
date: 2026-07-05
tags:
- attack.lateral-movement
- attack.t1021.006
logsource:
product: windows
category: ps_script
definition: 'Requirements: Script Block Logging must be enabled'
detection:
selection_cmdlet:
ScriptBlockText|contains|all:
- 'invoke-command '
- ' -ComputerName '
condition: selection_cmdlet
falsepositives:
- Unknown
level: medium
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.