Try in Splunk Security Cloud


This Splunk analytic detects when emails are accessed in Office 365 Exchange via the Microsoft Graph API, identified by the client ID '00000003-0000-0000-c000-000000000000'. It tracks the 'MailItemsAccessed' operation within the Exchange workload, focusing on OAuth-authenticated applications. The query compiles statistics on access frequency, timing, and client IP addresses, organized by user, client application ID, and AppId. For defenders, it's crucial to maintain an inventory of all OAuth applications that read emails, using this data to scrutinize and identify any potential abusive access patterns.

  • Type: TTP
  • Product: Splunk Enterprise, Splunk Enterprise Security, Splunk Cloud

  • Last Updated: 2024-01-31
  • Author: Mauricio Velazco, Splunk
  • ID: 9db0d5b0-4058-4cb7-baaf-77d8143539a2




ID Technique Tactic
T1114.002 Remote Email Collection Collection
Kill Chain Phase
  • Exploitation
  • DE.CM
  • CIS 10
 `o365_management_activity` Workload=Exchange Operation=MailItemsAccessed AppId=* AppId=00000003-0000-0000-c000-000000000000 
|  stats count earliest(_time) as firstTime latest(_time) as lastTime values(ClientIPAddress) by user ClientAppId OperationCount AppId 
| `security_content_ctime(firstTime)` 
| `security_content_ctime(lastTime)` 
| `o365_oauth_app_mailbox_access_via_graph_api_filter`


The SPL above uses the following Macros:

:information_source: o365_oauth_app_mailbox_access_via_graph_api_filter is a empty macro by default. It allows the user to filter out any results (false positives) without editing the SPL.

Required fields

List of fields required to use this analytic.

  • _time
  • Workload
  • Operation
  • AppId
  • ClientAppId
  • OperationCount

How To Implement

You must install the Splunk Microsoft Office 365 Add-on and ingest Office 365 management activity events.

Known False Positives

OAuth applications may access mailboxes for legitimate purposes, you can use the ClientAppId to add trusted applications to an allow list.

Associated Analytic Story


Risk Score Impact Confidence Message
42.0 70 60 An OAuth application identified with id $ClientAppId$ accesed mailboxes through the Graph API.

:information_source: The Risk Score is calculated by the following formula: Risk Score = (Impact * Confidence/100). Initial Confidence and Impact is set by the analytic author.


Test Dataset

Replay any dataset to Splunk Enterprise by using our tool or the UI. Alternatively you can replay a dataset into a Splunk Attack Range

source | version: 1