Detection rules › Splunk
O365 Email Security Feature Changed
The following analytic identifies when specific O365 advanced security settings are altered within the Office 365 tenant. If an attacker successfully disables O365 security settings, they can operate within the tenant with reduced risk of detection. This can lead to unauthorized data access, data exfiltration, account compromise, or other malicious activities without leaving a detailed audit trail.
Known false positives
- Administrators might alter features for troubleshooting, performance reasons, or other administrative tasks. Filter as needed.
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Defense Impairment |
Telemetry coverage
| Platform | Record / event type |
|---|---|
| Microsoft 365 | Exchange audit operation any: Federated domain added |
Rules detecting the same action
These rules filter on the same operation.
- O365 Email Transport Rule Changed (Splunk)
Rule body
name: O365 Email Security Feature Changed
id: 4d28013d-3a0f-4d65-a33f-4e8009fee0ae
version: 12
creation_date: '2024-04-07'
modification_date: '2026-05-13'
author: Steven Dick
status: production
type: TTP
description: The following analytic identifies when specific O365 advanced security settings are altered within the Office 365 tenant. If an attacker successfully disables O365 security settings, they can operate within the tenant with reduced risk of detection. This can lead to unauthorized data access, data exfiltration, account compromise, or other malicious activities without leaving a detailed audit trail.
data_source:
- Office 365 Universal Audit Log
search: |-
`o365_management_activity` Workload=Exchange AND Operation IN ("Set-*","Disable-*","New-*","Remove-*") Operation IN ("*AntiPhish*","*SafeLink*","*SafeAttachment*","*Malware*")
| rename Id as object_id, UserId as user, Operation as signature, ObjectId as object
| fillnull
| stats count min(_time) as firstTime max(_time) as lastTime
BY dest user src
vendor_account vendor_product signature
object_id object
| `security_content_ctime(firstTime)`
| `security_content_ctime(lastTime)`
| `o365_email_security_feature_changed_filter`
how_to_implement: You must install the Splunk Microsoft Office 365 Add-on and ingest Office 365 management activity events.
known_false_positives: Administrators might alter features for troubleshooting, performance reasons, or other administrative tasks. Filter as needed.
references:
- https://learn.microsoft.com/en-us/entra/fundamentals/security-defaults
- https://attack.mitre.org/techniques/T1562/008/
finding:
title: An O365 security object [$object$] was altered by user $user$ using $signature$
entity:
field: user
type: user
score: 50
analytic_story:
- Office 365 Persistence Mechanisms
- Office 365 Account Takeover
asset_type: O365 Tenant
mitre_attack_id:
- T1685.002
product:
- Splunk Enterprise
- Splunk Enterprise Security
- Splunk Cloud
category: cloud
security_domain: threat
Stages and Predicates
Stage 1: search
`o365_management_activity` Workload=Exchange AND Operation IN ("Set-*","Disable-*","New-*","Remove-*") Operation IN ("*AntiPhish*","*SafeLink*","*SafeAttachment*","*Malware*")
Stage 2: rename
| rename Id as object_id, UserId as user, Operation as signature, ObjectId as object
Stage 3: fillnull
| fillnull
Stage 4: stats
| stats count min(_time) as firstTime max(_time) as lastTime
BY dest user src
vendor_account vendor_product signature
object_id object
Stage 5: search
| `security_content_ctime(firstTime)`
Stage 6: search
| `security_content_ctime(lastTime)`
Stage 7: search
| `o365_email_security_feature_changed_filter`
Indicators
These rows show field, operator, and value matches.
| Field | Kind | Values | Search |
|---|---|---|---|
Operation | in |
| field:"Operation" kind:in |
Workload | eq |
| field:"Workload" kind:eq value:"Exchange" |
sourcetype | eq |
| field:"sourcetype" kind:eq value:"o365:management:activity" |