Try in Splunk Security Cloud


The following analytic identifies instances where admin consent is granted to an application within an Azure AD and Office 365 tenant. It leverages O365 audit logs, specifically events related to the admin consent action within the AzureActiveDirectory workload. The admin consent action allows applications to access data across the entire tenant, potentially encompassing a vast amount of organizational data. Given its broad scope and the sensitivity of some permissions that can only be granted via admin consent, it's crucial to monitor this action. Unauthorized or inadvertent granting of admin consent can lead to significant security risks, including data breaches, unauthorized data access, and potential compliance violations. If an attacker successfully tricks an administrator into granting admin consent to a malicious or compromised application, they can gain extensive and persistent access to organizational data. This can lead to data exfiltration, espionage, further malicious activities within the tenant, and potential breaches of compliance regulations

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

  • Last Updated: 2023-09-06
  • Author: Mauricio Velazco, Splunk
  • ID: 50eaabf8-5180-4e86-bfb2-011472c359fc




ID Technique Tactic
T1098 Account Manipulation Persistence, Privilege Escalation
T1098.003 Additional Cloud Roles Persistence, Privilege Escalation
Kill Chain Phase
  • Installation
  • Exploitation
  • DE.CM
  • CIS 10
`o365_management_activity` Operation="Consent to application."  
| eval new_field=mvindex('ModifiedProperties{}.NewValue', 4) 
| rex field=new_field "ConsentType: (?<ConsentType>[^\,]+)" 
| rex field=new_field "Scope: (?<Scope>[^\,]+)"  
| search  ConsentType = "AllPrincipals"  
| stats count min(_time) as firstTime max(_time) as lastTime by Operation, user, object, ObjectId, ConsentType, Scope 
| `security_content_ctime(firstTime)`  
| `security_content_ctime(lastTime)` 
| `o365_tenant_wide_admin_consent_granted_filter`


The SPL above uses the following Macros:

:information_source: o365_tenant_wide_admin_consent_granted_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
  • Operation
  • user
  • object
  • ObjectId
  • ModifiedProperties{}.NewValue

How To Implement

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

Known False Positives

Legitimate applications may be granted tenant wide consent, filter as needed.

Associated Analytic Story


Risk Score Impact Confidence Message
45.0 90 50 The $object$ application registration was granted tenant wide admin consent.

: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