Skip to content

Commit 613bfbb

Browse files
authored
add Azure Run Command script drop detection
adds new detection rule for PowerShell scripts created by the Azure Run Command feature on Windows hosts which addresses a visibility gap where Azure Activity Logs do not capture the script content.
1 parent 6d58176 commit 613bfbb

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed
Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
title: Azure Run Command Script File Creation
2+
id: 3f896781-c907-4781-b018-781907152519
3+
related:
4+
- id: 5a2e6f43-85f2-4e6a-8d3b-9c2e1f4a5b6c
5+
type: similar
6+
status: test
7+
description: |
8+
Detects creation of PowerShell scripts in the Azure Run Command plugin directory.
9+
According to Mandiant research, Azure Activity Logs don't capture script contents by default,
10+
making file monitoring critical for detecting malicious commands. Scripts are downloaded to
11+
a predictable path before execution, allowing detection of the actual malicious code being
12+
pushed to virtual machines via Azure Run Command.
13+
author: Vladan Sekulic
14+
date: 2025-12-17
15+
references:
16+
- https://cloud.google.com/blog/topics/threat-intelligence/azure-run-command-dummies
17+
logsource:
18+
product: windows
19+
category: file_event
20+
detection:
21+
selection:
22+
TargetFilename|contains|all:
23+
- '\Packages\Plugins\Microsoft.CPlat.Core.RunCommandWindows\'
24+
- '\Downloads\script'
25+
TargetFilename|endswith: '.ps1'
26+
condition: selection
27+
falsepositives:
28+
- Legitimate administrative scripts executed via Azure Run Command
29+
- Automated patching and configuration management
30+
- Azure Automation runbooks
31+
level: medium
32+
tags:
33+
- attack.execution
34+
- attack.t1059.001

0 commit comments

Comments
 (0)