Microsoft Teams External versus Internal Thread Exposure


Description

This query shows de-duplicated Microsoft Teams messages split by whether the thread includes external participants.

Query · kql

//This query shows de-duplicated Microsoft Teams messages split by whether the thread includes external participants.
MessageEvents
| where Timestamp > ago(30d)
| summarize arg_max(Timestamp, *) by TeamsMessageId
| extend Thread = iif(IsExternalThread == true, "External Thread", "Internal Thread")
| summarize Count = count() by Thread
| render piechart
Raw source Microsoft Teams External versus Internal Thread Exposure · KQL
Esc
Published by Azure/Azure-Sentinel ↗, licensed under MIT ↗. Reproduced here unmodified.
id: b26c8461-8c9e-47ff-8b61-fe0f1fb8eea4
name: Microsoft Teams External versus Internal Thread Exposure
description: |
  This query shows de-duplicated Microsoft Teams messages split by whether the thread includes external participants.
description-detailed: |
  This query shows de-duplicated Microsoft Teams messages split by whether the thread includes external participants, using Advanced hunting in Microsoft Defender XDR. External threads carry the higher risk of social-engineering and malicious content.
requiredDataConnectors:
- connectorId: MicrosoftThreatProtection
  dataTypes:
  - MessageEvents
tactics:
  - InitialAccess
relevantTechniques:
  - T1566
query: |
  //This query shows de-duplicated Microsoft Teams messages split by whether the thread includes external participants.
  MessageEvents
  | where Timestamp > ago(30d)
  | summarize arg_max(Timestamp, *) by TeamsMessageId
  | extend Thread = iif(IsExternalThread == true, "External Thread", "Internal Thread")
  | summarize Count = count() by Thread
  | render piechart
version: 1.0.0

Detection rules belong to the projects that publish them and remain under their own licenses. This site indexes and links to them; it claims no rights in them.