PIVTR-D
RCloud playbooks

Azure playbooks

This page covers Azure subscriptions and the Microsoft Entra ID tenant behind them: the logs to keep, what to search, and the playbooks for 22 incident types in seven categories. Each playbook lists where to look and the commands to contain it. Commands use the Azure CLI and Microsoft Graph PowerShell, and queries are Kusto Query Language (KQL) for a Log Analytics workspace or Microsoft Sentinel.

Playbooks

Identity and access

Stolen credentials, taken-over accounts and the access an attacker leaves behind.

Compute and containers

Workloads, servers and clusters used or abused by an attacker.

Data and storage

Exposed, copied, encrypted or deleted data, and stolen secrets.

Network and edge

Attacks on availability and on names and endpoints you own.

Pipelines and supply chain

Build systems and image registries that reach production.

Evasion and guardrails

Logging and controls turned off to hide an attack.

Provider and accidental

Incidents with no attacker: a vendor's bug, a provider's or operator's mistake, or a provider outage.

First 15 minutes, any incident

#Item
1Save the Activity Log for each affected subscription. The Activity Log keeps 90 days: az monitor activity-log list --start-time <yyyy-mm-dd> --offset 30d --max-events 10000 -o json > activity-<sub>.json
2Export Entra audit and sign-in logs for the window before the 7-day or 30-day limit removes them
3Identify the caller from Caller and CallerIpAddress in AzureActivity and from InitiatedBy in AuditLogs
4List the caller's Azure roles in each subscription: az role assignment list --assignee <object-id> --all --include-inherited
5Snapshot the disks of affected virtual machines (VMs): az snapshot create -g <rg> -n <case-id>-<disk> --source <disk-id> --tags case=<case-id>
6Lock the Log Analytics workspace against deletion: az lock create --name ir-nodelete --lock-type CanNotDelete -g <rg> --resource <workspace> --resource-type Microsoft.OperationalInsights/workspaces
7Record every command, its time and its operator in T3

Native detections to playbooks

Each row names a built-in alert or risk detection, the service that raises it, and the playbook to open when it fires.

DetectionSourceOpen
Leaked CredentialsEntra ID Protection, workload identitiesService principal secret
Unfamiliar sign-in propertiesEntra ID ProtectionEntra ID user
Attacker in the MiddleEntra ID ProtectionEntra ID user
Anomalous service principal activityEntra ID Protection, workload identitiesApps, credentials, federation
Token issuer anomalyEntra ID ProtectionApps, credentials, federation
Usage of NetSPI techniques to maintain persistence in your Azure environmentDefender for Resource ManagerApps, credentials, federation
Suspicious elevate access operationDefender for Resource ManagerGlobal Administrator
Anomalous user activityEntra ID ProtectionGlobal Administrator
Azure Resource Manager operation from suspicious IP addressDefender for Resource ManagerManaged identity
Run Command with a suspicious script was detected on your virtual machine (Preview)Defender for Cloud, Azure VM extension alertsVirtual machine
Kubernetes control plane and workload runtime alerts. The reference lists categories without alert namesDefender for ContainersAzure AKS
Suspicious creation of compute resources detectedDefender for Resource ManagerVirtual machines
Digital currency mining related behavior detectedDefender for ServersVirtual machines
The access level of a potentially sensitive storage blob container was changed to allow unauthenticated public accessDefender for StorageStorage accounts
Unusual amount of data extracted from a storage accountDefender for StorageStorage accounts
Login from a suspicious IPDefender for SQLSQL and databases
Potential SQL injectionDefender for SQLSQL and databases
Unusual deletion in a storage accountDefender for StorageDeletion and ransomware
Suspicious invocation of a high-risk 'Impact' operation detected (Preview)Defender for Resource ManagerDeletion and ransomware
Suspicious secret listing and query in a key vaultDefender for Key VaultKey Vault
Suspicious key vault recovery detectedDefender for Resource ManagerKey Vault
DDoS Attack detected for Public IPAzure DDoS Protection, in Defender for CloudDDoS Protection and WAF
Dangling DNS alert, raised when an App Service site is deleted and its custom domain remains. The reference publishes no alert nameDefender for App ServiceAzure DNS records
Azure DevOps Service Connection AbuseMicrosoft Sentinel, Azure DevOps Auditing solutionDevOps and federated credentials
Suspicious invocation of a high-risk 'Defense Evasion' operation detected (Preview)Defender for Resource ManagerDiagnostic settings, Defender, Policy
AI.Azure_DOWVolumeAnomalyDefender for Cloud, AI services planAzure OpenAI
AI.Azure_AccessFromSuspiciousIPDefender for Cloud, AI services planAzure OpenAI
AI.Azure_CredentialTheftAttemptDefender for Cloud, AI services planAzure OpenAI
AI.Azure_Jailbreak.ContentFiltering.DetectedAttemptDefender for Cloud, AI services planAzure OpenAI

Microsoft Learn: Defender for Cloud alerts reference for Resource Manager, Storage, Key Vault, SQL Database and Azure Synapse Analytics, Windows and Linux machines, Azure VM extensions, containers, App Service, DDoS Protection and AI services; Defender for App Service introduction; Entra ID Protection risk detections; securing workload identities. Microsoft Sentinel repository: Azure DevOps Auditing solution analytic rules. Defender for Cloud alert references checked October 2026. Defender for App Service introduction, Entra ID Protection risk detections, workload identities and the Sentinel rules: checked September 2026.

Before an incident

LogDefault retentionTurn on / keep
Azure Activity Log (control plane)90 days, collected automaticallySubscription diagnostic setting to the workspace, table AzureActivity. The first 90 days there carry no retention charge. Include the Administrative, Security and Policy categories
Entra audit logs7 days on Entra ID Free, 30 days with P1 or P2Entra diagnostic setting, category AuditLogs, table AuditLogs
Entra sign-in logs: interactive, non-interactive, service principal, managed identity7 days on Free, 30 days with P1 or P2Categories SignInLogs, NonInteractiveUserSignInLogs, ServicePrincipalSignInLogs, ManagedIdentitySignInLogs. Tables SigninLogs, AADNonInteractiveUserSignInLogs, AADServicePrincipalSignInLogs, AADManagedIdentitySignInLogs
Entra ID Protection risk dataRisky sign-ins 7 days on Free, 30 days on P1, 90 days on P2. Risky users stay until the risk is remediatedCategories RiskyUsers and UserRiskEvents, tables AADRiskyUsers and AADUserRiskEvents
Microsoft Graph activity logsOff by default, and kept only where you send themCategory MicrosoftGraphActivityLogs, same table name. Needs Entra ID P1 or P2
Blob storage resource logsNot collected by defaultDiagnostic setting on each account's blobServices/default with StorageRead, StorageWrite, StorageDelete. Table StorageBlobLogs
Virtual network flow logsOff by default. Retention is set per flow logNetwork security group (NSG) flow logs accept no new creation and retire on September 30, 2027. Create virtual network flow logs: az network watcher flow-log create --location <region> --name <name> --vnet <vnet> --storage-account <account> --retention <days>
Microsoft Defender for Cloud alertsShown in the portal for 90 daysEnable Defender plans. Turn on continuous export to the workspace, tables SecurityAlert and SecurityRecommendation
Log Analytics workspace30 days analytics retention per table, 90 days for AzureActivityRaise retention on identity and storage tables (up to 730 days analytics, 12 years total). Add a CanNotDelete lock
Azure PolicyPolicy events in the Activity Log, 90 daysAssign the built-in Allowed locations policy (e56962a6-4747-49cd-b67b-bf8b01975c4c) at the management group

Microsoft Learn: Entra data retention, Entra diagnostic setting log options, ID Protection data export, Azure Monitor activity log, diagnostic settings, Log Analytics retention, Graph activity logs, secure Network Watcher (VNet and NSG flow logs), Azure Policy tutorial, Azure CLI reference for az monitor activity-log and az network watcher flow-log. Checked October 2026, including the 90-day Defender for Cloud alert display (alerts overview). Continuous export: checked September 2026.

Adapts material from Dynamic Incident Response: A Framework for Security Teams by Joshua Wright, © 2026 The Escal Institute of Advanced Technologies, Inc. d/b/a SANS Institute, licensed under CC BY 4.0. Figures reproduced under that license. Changes were made. Not published by, endorsed by, or affiliated with the SANS Institute.