Microsoft Teams Impersonation Identities by Fake Display Name
Description
This query groups Microsoft Teams impersonation detections by the fake display name and sender domain to expose bulk campaigns behind rotating addresses.
Query · kql
//This query groups Microsoft Teams impersonation detections over the last 30 days by fake display name, sender
//domain and impersonation type, with the count of distinct sending addresses behind each identity.
//Attackers rotate sending addresses under one display name, so per-address ranking scatters a single campaign
//into many low-count rows. Distinct Sender Addresses is what reveals the bulk activity.
CloudAppEvents
| where Timestamp > ago(30d)
| where ActionType == "TeamsImpersonationDetected"
| extend RD = parse_json(RawEventData)
| extend ImpersonationType = tostring(RD.ImpersonationType),
FakeDisplayName = tostring(RD.Sender.DisplayName),
FakeSenderAddress = tostring(RD.Sender.UPN),
TargetUser = tostring(RD.UserId)
| extend FakeSenderDomain = tolower(tostring(split(FakeSenderAddress, "@")[1]))
| where isnotempty(FakeSenderDomain)
| summarize Detections = count(), SenderAddresses = dcount(FakeSenderAddress),
Targets = dcount(TargetUser), FirstSeen = min(Timestamp), LastSeen = max(Timestamp)
by FakeDisplayName, FakeSenderDomain, ImpersonationType
| top 20 by Detections desc
| project ['Fake Display Name']=FakeDisplayName, ['Sender Domain']=FakeSenderDomain,
['Impersonation Type']=ImpersonationType, ['Distinct Sender Addresses']=SenderAddresses,
['Detections']=Detections, ['Targeted Users']=Targets,
['First Seen']=FirstSeen, ['Last Seen']=LastSeen