← Back to SOC feed Coverage →

Spoof and impersonation detections by sender IP

kql MEDIUM Azure-Sentinel
T1566
EmailEvents
huntingmicrosoftofficial
This rule was pulled from an open-source repository and enriched with AI. Validate in a test environment before deploying to production.
View original rule at Azure-Sentinel →
Retrieved: 2026-05-18T11:00:00Z · Confidence: medium

Hunt Hypothesis

Adversaries may spoof sender IP addresses to impersonate legitimate users or systems, enabling phishing or credential theft. SOC teams should proactively hunt for this behavior in Azure Sentinel to identify and mitigate potential impersonation attacks before they lead to data exfiltration or lateral movement.

KQL Query

EmailEvents 
|where Timestamp > ago (30d) and (DetectionMethods contains 'spoof' or DetectionMethods contains "impersonation")  
| project Timestamp, EmailDirection, SenderFromAddress, AdditionalFields, SenderIPv4 
| summarize count() by SenderIPv4

Analytic Rule Definition

id: b3180ac0-6d94-494a-8b8c-fcc84319ea6e
name: Spoof and impersonation detections by sender IP
description: |
  This query helps reviewing count of spoof and impersonation detections done per sender IP
description-detailed: |
  This query helps reviewing count of spoof and impersonation detections done per sender IP using Defender for Office 365 data.
  Reference - https://techcommunity.microsoft.com/t5/microsoft-defender-for-office/email-protection-basics-in-microsoft-365-spoof-and-impersonation/ba-p/3562938#:~:text=It%20detects%20impersonation%20based%20on%20each%20user%E2%80%99s%20individual
requiredDataConnectors:
- connectorId: MicrosoftThreatProtection
  dataTypes:
  - EmailEvents
tactics:
  - InitialAccess
relevantTechniques:
  - T1566
query: |
  EmailEvents 
  |where Timestamp > ago (30d) and (DetectionMethods contains 'spoof' or DetectionMethods contains "impersonation")  
  | project Timestamp, EmailDirection, SenderFromAddress, AdditionalFields, SenderIPv4 
  | summarize count() by SenderIPv4
version: 1.0.0

Required Data Sources

Sentinel TableNotes
EmailEventsEnsure this data connector is enabled

MITRE ATT&CK Context

References

False Positive Guidance

Original source: https://github.com/Azure/Azure-Sentinel/blob/main/Hunting Queries/Microsoft 365 Defender/Email and Collaboration Queries/Spoof and Impersonation/Spoof and impersonation detections by sender IP.yaml