Detection rules › Splunk
O365 Multiple Users Failing To Authenticate From Ip
The following analytic identifies instances where more than 10 unique user accounts fail to authenticate from a single IP address within a 5-minute window. This detection leverages O365 audit logs, specifically Azure Active Directory login failures (AzureActiveDirectoryStsLogon). Such activity is significant as it may indicate brute-force attacks or password spraying attempts. If confirmed malicious, this behavior suggests an external entity is attempting to breach security by targeting multiple accounts, potentially leading to unauthorized access. Immediate action is required to block or monitor the suspicious IP and notify affected users to enhance their security measures.
MITRE ATT&CK coverage
| Tactic | Techniques |
|---|---|
| Resource Development | T1586.003 Compromise Accounts: Cloud Accounts |
| Credential Access | T1110.003 Brute Force: Password Spraying, T1110.004 Brute Force: Credential Stuffing |
Rules detecting the same action
Other rules on this platform that filter on the same API call or operation.
- High Number of Login Failures from a single source (Splunk)
- M365 Identity User Account Lockouts (Elastic)
- M365 Identity User Brute Force Attempted (Elastic)
- O365 Excessive SSO logon errors (Splunk)
- O365 High Number Of Failed Authentications for User (Splunk)
- O365 Multi-Source Failed Authentications Spike (Splunk)
- O365 Multiple AppIDs and UserAgents Authentication Spike (Splunk)
- O365 Multiple Failed MFA Requests For User (Splunk)
Rule body splunk
name: O365 Multiple Users Failing To Authenticate From Ip
id: 8d486e2e-3235-4cfe-ac35-0d042e24ecb4
version: 13
creation_date: '2023-12-06'
modification_date: '2026-05-13'
author: Mauricio Velazco, Splunk
status: production
type: TTP
description: The following analytic identifies instances where more than 10 unique user accounts fail to authenticate from a single IP address within a 5-minute window. This detection leverages O365 audit logs, specifically Azure Active Directory login failures (AzureActiveDirectoryStsLogon). Such activity is significant as it may indicate brute-force attacks or password spraying attempts. If confirmed malicious, this behavior suggests an external entity is attempting to breach security by targeting multiple accounts, potentially leading to unauthorized access. Immediate action is required to block or monitor the suspicious IP and notify affected users to enhance their security measures.
data_source:
- O365 UserLoginFailed
search: |-
`o365_management_activity` Workload=AzureActiveDirectory Operation=UserLoginFailed ErrorNumber=50126
| bucket span=5m _time
| fillnull
| stats dc(user) as unique_accounts values(user) as user values(LogonError) as LogonError values(signature) as signature values(UserAgent) as user_agent values(dest) as dest
BY _time src vendor_account
vendor_product
| where unique_accounts > 10
| `o365_multiple_users_failing_to_authenticate_from_ip_filter`
how_to_implement: You must install the Splunk Microsoft Office 365 Add-on and ingest Office 365 management activity events.
known_false_positives: A source Ip failing to authenticate with multiple users in a short period of time is not common legitimate behavior.
references:
- https://attack.mitre.org/techniques/T1110/003/
- https://docs.microsoft.com/en-us/security/compass/incident-response-playbook-password-spray
- https://www.cisa.gov/uscert/ncas/alerts/aa21-008a
- https://docs.microsoft.com/azure/active-directory/reports-monitoring/reference-sign-ins-error-codes
drilldown_searches:
- name: View the detection results for - "$user$"
search: '%original_detection_search% | search user = "$user$"'
earliest_offset: $info_min_time$
latest_offset: $info_max_time$
- name: View risk events for the last 7 days for - "$user$"
search: '| from datamodel Risk.All_Risk | search normalized_risk_object IN ("$user$") | stats count min(_time) as firstTime max(_time) as lastTime values(search_name) as "Search Name" values(risk_message) as "Risk Message" values(analyticstories) as "Analytic Stories" values(annotations._all) as "Annotations" values(annotations.mitre_attack.mitre_tactic) as "ATT&CK Tactics" by normalized_risk_object | `security_content_ctime(firstTime)` | `security_content_ctime(lastTime)`'
earliest_offset: 7d
latest_offset: "0"
finding:
title: Source Ip $src$ failed to authenticate with 20 users within 5 minutes.
entity:
field: user
type: user
score: 50
threat_objects:
- field: src
type: ip_address
analytic_story:
- Office 365 Account Takeover
- NOBELIUM Group
asset_type: O365 Tenant
mitre_attack_id:
- T1110.003
- T1110.004
- T1586.003
product:
- Splunk Enterprise
- Splunk Enterprise Security
- Splunk Cloud
category: cloud
security_domain: identity
tests:
- name: True Positive Test
attack_data:
- data: https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/attack_techniques/T1110.003/o365_multiple_users_from_ip/o365_multiple_users_from_ip.log
source: o365
sourcetype: o365:management:activity
test_type: unit
Stages and Predicates
Stage 1: search
`o365_management_activity` Workload=AzureActiveDirectory Operation=UserLoginFailed ErrorNumber=50126
Stage 2: bucket
| bucket span=5m _time
Stage 3: fillnull
| fillnull
Stage 4: stats
| stats dc(user) as unique_accounts values(user) as user values(LogonError) as LogonError values(signature) as signature values(UserAgent) as user_agent values(dest) as dest
BY _time src vendor_account
vendor_product
Stage 5: where
| where unique_accounts > 10
Stage 6: search
| `o365_multiple_users_failing_to_authenticate_from_ip_filter`
Indicators
Each row is a field, operator, and value that the rule matches. The corpus column counts how many other rules in the catalog look for the same combination: high numbers point to widely-used, community-vetted indicators. Blank or 1 shows that the indicator is specific to this rule.
| Field | Kind | Values |
|---|---|---|
ErrorNumber | eq |
|
Operation | eq |
|
Workload | eq |
|
sourcetype | eq |
|
unique_accounts | gt |
|