Azure custom policy is not working. Need help!!!!

Occasional Contributor



Trying to check whether SecurityContacts/email presents with this policy. It is not showing. Also the policy execution interval is intermittent. 


"policyRule": {
"if": {
"field": "type",
"equals": "Microsoft.Security/securityContacts"
"then": {
"effect": "AuditIfNotExists",
"details": {
"type": "Microsoft.Security/securityContacts",
"existenceCondition": {
"field": "Microsoft.Security/securityContacts/email",
"exists": "true"
1 Reply

Fixed the issue. The issue is that email attribute is null though the SecurityContacts settings is not enabled. So need to check for null values which made the policy to trigger vilations..


This issue can be closed..