AZT508 - Azure Policy
Hello all :)
I have designed the following simple KQL query to monitor for potential misuse of the DeployIfNotExists effect by detecting policy definition updates:
AzureActivity
| where OperationNameValue == 'MICROSOFT.AUTHORIZATION/POLICYDEFINITIONS/WRITE'
| where ActivityStatusValue == "Success"
| extend CallerList = split(Caller, '@')
| project
TimeGenerated,
SubscriptionId,
Caller,
CallerIpAddress,
_ResourceId,
Name = CallerList[0],
UPNSUffix = CallerList[1]
My goal is to detect attempts to exploit the automated deployment mechanism by monitoring successful updates to policy definitions. Could you confirm if this query is sufficient for monitoring such activities, or would you recommend additional logic or enhancements?
For example, is it necessary to correlate these updates with subsequent deployments or include additional filtering criteria to improve detection? Thank you in advance for your guidance!
Source: https://microsoft.github.io/Azure-Threat-Research-Matrix/Persistence/AZT508/AZT508/
Thank you :)