AzureActivity Compromised Account


Description

This query list all the actions (ACTION, DELETE, WRITE, etc) by a compromised account.

Query · kql

let CompromisedAccountUPN = "test@test.com";
let SearchWindow = 48h; //Customizable h = hours, d = days
AzureActivity
| where Caller =~ CompromisedAccountUPN
| where TimeGenerated > ago(SearchWindow)
| summarize TotalEvents = count() by OperationNameValue
| sort by TotalEvents desc
Raw source AzureActivity Compromised Account · KQL
Esc
Published by Bert-JanP/Hunting-Queries-Detection-Rules ↗, licensed under BSD 3-Clause ↗. Reproduced here unmodified.
# AzureActivity Compromised Account

## Query Information

#### Description
This query list all the actions (ACTION, DELETE, WRITE, etc) by a compromised account.

## Defender XDR
```
let CompromisedAccountUPN = "test@test.com";
let SearchWindow = 48h; //Customizable h = hours, d = days
AzureActivity
| where Caller =~ CompromisedAccountUPN
| where TimeGenerated > ago(SearchWindow)
| summarize TotalEvents = count() by OperationNameValue
| sort by TotalEvents desc 
```
## Sentinel
```
let CompromisedAccountUPN = "test@test.com";
let SearchWindow = 48h; //Customizable h = hours, d = days
AzureActivity
| where Caller =~ CompromisedAccountUPN
| where TimeGenerated > ago(SearchWindow)
| summarize TotalEvents = count() by OperationNameValue
| sort by TotalEvents desc 
```

Detection rules belong to the projects that publish them and remain under their own licenses. This site indexes and links to them; it claims no rights in them.