Back
Id44ec1fa4-a502-41ae-879a-3aad3557edce
RulenameValimail Enforce - DMARC Policy Weakened to None
DescriptionThis query searches for DMARC policies changed to ’none’, which disables enforcement

and leaves the domain vulnerable to spoofing and phishing attacks.
SeverityHigh
TacticsDefenseEvasion
InitialAccess
TechniquesT1566
T1562
Required data connectorsValimailEnforce
KindScheduled
Query frequency1h
Query period1h
Trigger threshold0
Trigger operatorgt
Source Urihttps://github.com/Azure/Azure-Sentinel/blob/master/Solutions/ValimailEnforce/Analytic%20Rules/ValimailEnforce_DMARCPolicyWeakened.yaml
Version1.0.0
Arm template44ec1fa4-a502-41ae-879a-3aad3557edce.json
Deploy To Azure
ValimailEnforceEvents_CL
| where EventSeverity == "High"
| where EventType == "dmarc_policy_set_to_none"
| summarize
    EventCount = count(),
    FirstSeen = min(PerformedAt),
    LastSeen = max(PerformedAt),
    Changes = make_set(EventChange)
  by Subject, User, EventCategory
| extend
    AccountName = tostring(split(User, "@")[0]),
    AccountDomain = tostring(split(User, "@")[1]),
    DomainName = Subject
tactics:
- DefenseEvasion
- InitialAccess
requiredDataConnectors:
- dataTypes:
  - ValimailEnforceEvents_CL
  connectorId: ValimailEnforce
incidentConfiguration:
  createIncident: true
  groupingConfiguration:
    groupByEntities:
    - DNS
    matchingMethod: Selected
    enabled: true
    reopenClosedIncident: false
    lookbackDuration: 1d
queryPeriod: 1h
kind: Scheduled
severity: High
OriginalUri: https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/ValimailEnforce/Analytic%20Rules/ValimailEnforce_DMARCPolicyWeakened.yaml
queryFrequency: 1h
triggerThreshold: 0
description: |
  This query searches for DMARC policies changed to 'none', which disables enforcement
  and leaves the domain vulnerable to spoofing and phishing attacks.
id: 44ec1fa4-a502-41ae-879a-3aad3557edce
triggerOperator: gt
alertDetailsOverride:
  alertDescriptionFormat: |
    The DMARC policy for domain '{{Subject}}' was set to 'none' by '{{User}}',
    disabling email authentication enforcement. This may expose the domain to spoofing.
  alertDisplayNameFormat: DMARC policy set to NONE on domain {{Subject}} by {{User}}
status: Available
relevantTechniques:
- T1566
- T1562
version: 1.0.0
name: Valimail Enforce - DMARC Policy Weakened to None
entityMappings:
- entityType: Account
  fieldMappings:
  - columnName: AccountName
    identifier: Name
  - columnName: AccountDomain
    identifier: UPNSuffix
- entityType: DNS
  fieldMappings:
  - columnName: DomainName
    identifier: DomainName
query: |
  ValimailEnforceEvents_CL
  | where EventSeverity == "High"
  | where EventType == "dmarc_policy_set_to_none"
  | summarize
      EventCount = count(),
      FirstSeen = min(PerformedAt),
      LastSeen = max(PerformedAt),
      Changes = make_set(EventChange)
    by Subject, User, EventCategory
  | extend
      AccountName = tostring(split(User, "@")[0]),
      AccountDomain = tostring(split(User, "@")[1]),
      DomainName = Subject
{
  "$schema": "https://schema.management.azure.com/schemas/2019-04-01/deploymentTemplate.json#",
  "contentVersion": "1.0.0.0",
  "parameters": {
    "workspace": {
      "type": "String"
    }
  },
  "resources": [
    {
      "apiVersion": "2024-01-01-preview",
      "id": "[concat(resourceId('Microsoft.OperationalInsights/workspaces/providers', parameters('workspace'), 'Microsoft.SecurityInsights'),'/alertRules/44ec1fa4-a502-41ae-879a-3aad3557edce')]",
      "kind": "Scheduled",
      "name": "[concat(parameters('workspace'),'/Microsoft.SecurityInsights/44ec1fa4-a502-41ae-879a-3aad3557edce')]",
      "properties": {
        "alertDetailsOverride": {
          "alertDescriptionFormat": "The DMARC policy for domain '{{Subject}}' was set to 'none' by '{{User}}',\ndisabling email authentication enforcement. This may expose the domain to spoofing.\n",
          "alertDisplayNameFormat": "DMARC policy set to NONE on domain {{Subject}} by {{User}}"
        },
        "alertRuleTemplateName": "44ec1fa4-a502-41ae-879a-3aad3557edce",
        "customDetails": null,
        "description": "This query searches for DMARC policies changed to 'none', which disables enforcement\nand leaves the domain vulnerable to spoofing and phishing attacks.\n",
        "displayName": "Valimail Enforce - DMARC Policy Weakened to None",
        "enabled": true,
        "entityMappings": [
          {
            "entityType": "Account",
            "fieldMappings": [
              {
                "columnName": "AccountName",
                "identifier": "Name"
              },
              {
                "columnName": "AccountDomain",
                "identifier": "UPNSuffix"
              }
            ]
          },
          {
            "entityType": "DNS",
            "fieldMappings": [
              {
                "columnName": "DomainName",
                "identifier": "DomainName"
              }
            ]
          }
        ],
        "incidentConfiguration": {
          "createIncident": true,
          "groupingConfiguration": {
            "enabled": true,
            "groupByEntities": [
              "DNS"
            ],
            "lookbackDuration": "P1D",
            "matchingMethod": "Selected",
            "reopenClosedIncident": false
          }
        },
        "OriginalUri": "https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/ValimailEnforce/Analytic%20Rules/ValimailEnforce_DMARCPolicyWeakened.yaml",
        "query": "ValimailEnforceEvents_CL\n| where EventSeverity == \"High\"\n| where EventType == \"dmarc_policy_set_to_none\"\n| summarize\n    EventCount = count(),\n    FirstSeen = min(PerformedAt),\n    LastSeen = max(PerformedAt),\n    Changes = make_set(EventChange)\n  by Subject, User, EventCategory\n| extend\n    AccountName = tostring(split(User, \"@\")[0]),\n    AccountDomain = tostring(split(User, \"@\")[1]),\n    DomainName = Subject\n",
        "queryFrequency": "PT1H",
        "queryPeriod": "PT1H",
        "severity": "High",
        "status": "Available",
        "subTechniques": [],
        "suppressionDuration": "PT1H",
        "suppressionEnabled": false,
        "tactics": [
          "DefenseEvasion",
          "InitialAccess"
        ],
        "techniques": [
          "T1562",
          "T1566"
        ],
        "templateVersion": "1.0.0",
        "triggerOperator": "GreaterThan",
        "triggerThreshold": 0
      },
      "type": "Microsoft.OperationalInsights/workspaces/providers/alertRules"
    }
  ]
}