Microsoft Sentinel Analytic Rules
cloudbrothers.infoAzure Sentinel RepoToggle Dark/Light/Auto modeToggle Dark/Light/Auto modeToggle Dark/Light/Auto modeBack to homepage

Google DNS - Multiple errors to same domain

Back
Idda04a5d6-e2be-4cba-8cdb-a3f2efa87e9e
RulenameGoogle DNS - Multiple errors to same domain
DescriptionDetects multiple errors to same domain.
SeverityMedium
TacticsCommandAndControl
TechniquesT1095
Required data connectorsGCPDNSDataConnector
KindScheduled
Query frequency1h
Query period1h
Trigger threshold0
Trigger operatorgt
Source Urihttps://github.com/Azure/Azure-Sentinel/blob/master/Solutions/GoogleCloudPlatformDNS/Analytic Rules/GCPDNSMultipleErrorsQuery.yaml
Version1.0.0
Arm templateda04a5d6-e2be-4cba-8cdb-a3f2efa87e9e.json
Deploy To Azure
let threshold = 2;
let err = dynamic(['NXDOMAIN', 'SERVFAIL', 'REFUSED']);
GCPCloudDNS
| where EventResultDetails in~ (err)
| summarize ips = makeset(SrcIpAddr) by Query, bin(TimeGenerated, 10m)
| where array_length(ips) >= threshold
| extend DNSCustomEntity = Query, IPCustomEntity = ips
relevantTechniques:
- T1095
name: Google DNS - Multiple errors to same domain
requiredDataConnectors:
- dataTypes:
  - GCPCloudDNS
  connectorId: GCPDNSDataConnector
entityMappings:
- fieldMappings:
  - identifier: DomainName
    columnName: DNSCustomEntity
  entityType: DNS
- fieldMappings:
  - identifier: Address
    columnName: IPCustomEntity
  entityType: IP
triggerThreshold: 0
id: da04a5d6-e2be-4cba-8cdb-a3f2efa87e9e
tactics:
- CommandAndControl
version: 1.0.0
OriginalUri: https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/GoogleCloudPlatformDNS/Analytic Rules/GCPDNSMultipleErrorsQuery.yaml
queryPeriod: 1h
kind: Scheduled
queryFrequency: 1h
severity: Medium
description: |
    'Detects multiple errors to same domain.'
query: |
  let threshold = 2;
  let err = dynamic(['NXDOMAIN', 'SERVFAIL', 'REFUSED']);
  GCPCloudDNS
  | where EventResultDetails in~ (err)
  | summarize ips = makeset(SrcIpAddr) by Query, bin(TimeGenerated, 10m)
  | where array_length(ips) >= threshold
  | extend DNSCustomEntity = Query, IPCustomEntity = ips  
triggerOperator: gt
{
  "$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/da04a5d6-e2be-4cba-8cdb-a3f2efa87e9e')]",
      "kind": "Scheduled",
      "name": "[concat(parameters('workspace'),'/Microsoft.SecurityInsights/da04a5d6-e2be-4cba-8cdb-a3f2efa87e9e')]",
      "properties": {
        "alertRuleTemplateName": "da04a5d6-e2be-4cba-8cdb-a3f2efa87e9e",
        "customDetails": null,
        "description": "'Detects multiple errors to same domain.'\n",
        "displayName": "Google DNS - Multiple errors to same domain",
        "enabled": true,
        "entityMappings": [
          {
            "entityType": "DNS",
            "fieldMappings": [
              {
                "columnName": "DNSCustomEntity",
                "identifier": "DomainName"
              }
            ]
          },
          {
            "entityType": "IP",
            "fieldMappings": [
              {
                "columnName": "IPCustomEntity",
                "identifier": "Address"
              }
            ]
          }
        ],
        "OriginalUri": "https://github.com/Azure/Azure-Sentinel/blob/master/Solutions/GoogleCloudPlatformDNS/Analytic Rules/GCPDNSMultipleErrorsQuery.yaml",
        "query": "let threshold = 2;\nlet err = dynamic(['NXDOMAIN', 'SERVFAIL', 'REFUSED']);\nGCPCloudDNS\n| where EventResultDetails in~ (err)\n| summarize ips = makeset(SrcIpAddr) by Query, bin(TimeGenerated, 10m)\n| where array_length(ips) >= threshold\n| extend DNSCustomEntity = Query, IPCustomEntity = ips\n",
        "queryFrequency": "PT1H",
        "queryPeriod": "PT1H",
        "severity": "Medium",
        "subTechniques": [],
        "suppressionDuration": "PT1H",
        "suppressionEnabled": false,
        "tactics": [
          "CommandAndControl"
        ],
        "techniques": [
          "T1095"
        ],
        "templateVersion": "1.0.0",
        "triggerOperator": "GreaterThan",
        "triggerThreshold": 0
      },
      "type": "Microsoft.OperationalInsights/workspaces/providers/alertRules"
    }
  ]
}