Skip to content

Commit 7b9d0de

Browse files
committed
Updating Azure Detections post BOTS
1 parent 26861eb commit 7b9d0de

File tree

3 files changed

+71
-49
lines changed

3 files changed

+71
-49
lines changed

detections/cloud/azure_ad_global_administrator_role_assigned.yml

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: Azure AD Global Administrator Role Assigned
22
id: 825fed20-309d-4fd1-8aaf-cd49c1bb093c
3-
version: 3
4-
date: '2022-08-17'
5-
author: Gowthamaraj Rajendran, Mauricio Velazco, Splunk
3+
version: 5
4+
date: '2024-06-25'
5+
author: Gowthamaraj Rajendran, Mauricio Velazco, Dean Luxton, Splunk
66
status: production
77
type: TTP
88
description: The following analytic identifies the assignment of the Azure AD Global
@@ -13,17 +13,20 @@ description: The following analytic identifies the assignment of the Azure AD Gl
1313
Azure services and resources, it is possible for a Global Administrator account
1414
to gain control of Azure resources. Adversaries and red teams alike may assign this
1515
role to a compromised account to establish Persistence or escalate their privileges in an Azure AD environment.
16-
data_source: []
17-
search: '`azuread` operationName="Add member to role" properties.targetResources{}.modifiedProperties{}.newValue="\"Global Administrator\""
18-
| rename properties.* as *
19-
| rename targetResources{}.userPrincipalName as userPrincipalName
20-
| rename initiatedBy.user.userPrincipalName as initiatedBy
21-
| stats values(userPrincipalName) as userPrincipalName by _time, initiatedBy, result, operationName
16+
data_source:
17+
- Azure Active Directory Add member to role
18+
search: '`azure_monitor_aad` operationName="Add member to role" properties.targetResources{}.modifiedProperties{}.newValue="\"Global Administrator\""
19+
| rename properties.* as *, initiatedBy.user.userPrincipalName as userPrincipalName, targetResources{}.displayName as displayName
20+
| eval initiatedBy = coalesce(userPrincipalName,src_user)
21+
| eval user = coalesce(user,mvfilter(displayName!="null"))
22+
| stats count min(_time) as firstTime max(_time) as lastTime values(user) as user by initiatedBy, result, operationName
23+
| `security_content_ctime(firstTime)`
24+
| `security_content_ctime(lastTime)`
2225
| `azure_ad_global_administrator_role_assigned_filter`'
2326
how_to_implement: You must install the latest version of Splunk Add-on for Microsoft
2427
Cloud Services from Splunkbase(https://splunkbase.splunk.com/app/3110/#/details).
2528
You must be ingesting Azure Active Directory events into your Splunk environment through an EventHub.
26-
Specifically, this analytic leverages the AuditLogs log category.
29+
This analytic was written to be used with the azure:monitor:aad sourcetype leveraging the AuditLogs log category.
2730
known_false_positives: Administrators may legitimately assign the Global Administrator
2831
role to a user. Filter as needed.
2932
references:
@@ -40,12 +43,12 @@ tags:
4043
asset_type: Azure Active Directory
4144
confidence: 90
4245
impact: 80
43-
message: Global Administrator Role assigned for User $userPrincipalName$ initiated
46+
message: Global Administrator Role assigned for User $user$ initiated
4447
by $initiatedBy$
4548
mitre_attack_id:
4649
- T1098.003
4750
observable:
48-
- name: userPrincipalName
51+
- name: user
4952
type: User
5053
role:
5154
- Victim
@@ -59,7 +62,7 @@ tags:
5962
- Splunk Cloud
6063
required_fields:
6164
- _time
62-
- properties.targetResources{}.userPrincipalName
65+
- user
6366
- properties.targetResources{}.type
6467
- properties.initiatedBy.user.userPrincipalName
6568
- properties.result
@@ -69,6 +72,6 @@ tests:
6972
- name: True Positive Test
7073
attack_data:
7174
- data: https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/attack_techniques/T1098.003/azure_ad_assign_global_administrator/azure-audit.log
72-
source: mscs:azure:eventhub
73-
sourcetype: mscs:azure:eventhub
74-
update_timestamp: true
75+
source: Azure AD
76+
sourcetype: azure:monitor:aad
77+
update_timestamp: true
Lines changed: 21 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,32 @@
11
name: Azure AD Privileged Role Assigned
22
id: a28f0bc3-3400-4a6e-a2da-89b9e95f0d2a
3-
version: 1
4-
date: '2022-08-29'
3+
version: 4
4+
date: '2024-06-25'
55
author: Mauricio Velazco, Gowthamaraj Rajendran, Splunk
66
status: production
77
type: TTP
88
description: The following analytic identifies the assignment of sensitive and privileged
99
Azure Active Directory roles to an Azure AD user. Adversaries and red teams alike
1010
may assign these roles to a compromised account to establish Persistence in an Azure
1111
AD environment.
12-
data_source: []
13-
search: ' `azuread` "operationName"="Add member to role" | rename properties.* as *
14-
| rename targetResources{}.userPrincipalName as userPrincipalName
15-
| rename initiatedBy.user.userPrincipalName as initiatedBy
12+
data_source:
13+
- Azure Active Directory Add member to role
14+
search: ' `azure_monitor_aad` "operationName"="Add member to role"
15+
| rename properties.* as *, initiatedBy.user.userPrincipalName as userPrincipalName, targetResources{}.displayName as displayName
16+
| eval initiatedBy = coalesce(userPrincipalName,src_user)
17+
| eval user = coalesce(user,mvfilter(displayName!="null"))
1618
| rename targetResources{}.modifiedProperties{}.newValue as roles
17-
| eval role=mvindex(roles,1)
19+
| eval role=mvindex(roles,1)
20+
| stats count min(_time) as firstTime max(_time) as lastTime values(user) as user by initiatedBy, result, operationName, role
1821
| lookup privileged_azure_ad_roles azureadrole AS role OUTPUT isprvilegedadrole description
19-
| search isprvilegedadrole = True
20-
| stats values(userPrincipalName) as userPrincipalName by _time, initiatedBy, result, operationName, role, description
22+
| search isprvilegedadrole = True
23+
| `security_content_ctime(firstTime)`
24+
| `security_content_ctime(lastTime)`
2125
| `azure_ad_privileged_role_assigned_filter`'
2226
how_to_implement: You must install the latest version of Splunk Add-on for Microsoft
2327
Cloud Services from Splunkbase (https://splunkbase.splunk.com/app/3110/#/details).
2428
You must be ingesting Azure Active Directory events into your Splunk environment.
25-
Specifically, this analytic leverages the AuditLogs log category.
29+
This analytic was written to be used with the azure:monitor:aad sourcetype leveraging the AuditLog log category.
2630
known_false_positives: Administrators will legitimately assign the privileged roles
2731
users as part of administrative tasks. Filter as needed.
2832
references:
@@ -35,16 +39,17 @@ references:
3539
tags:
3640
analytic_story:
3741
- Azure Active Directory Persistence
42+
- NOBELIUM Group
3843
asset_type: Azure Active Directory
3944
confidence: 90
4045
impact: 70
41-
message: A privileged Azure AD role was assigned for User $userPrincipalName$ initiated
46+
message: A privileged Azure AD role was assigned for User $user$ initiated
4247
by $initiatedBy$
4348
mitre_attack_id:
4449
- T1098
4550
- T1098.003
4651
observable:
47-
- name: userPrincipalName
52+
- name: user
4853
type: User
4954
role:
5055
- Victim
@@ -58,7 +63,7 @@ tags:
5863
- Splunk Cloud
5964
required_fields:
6065
- _time
61-
- properties.targetResources{}.userPrincipalName
66+
- user
6267
- properties.targetResources{}.type
6368
- properties.initiatedBy.user.userPrincipalName
6469
- properties.result
@@ -68,6 +73,6 @@ tests:
6873
- name: True Positive Test
6974
attack_data:
7075
- data: https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/attack_techniques/T1098.003/azure_ad_assign_privileged_role/azure-audit.log
71-
source: mscs:azure:eventhub
72-
sourcetype: mscs:azure:eventhub
73-
update_timestamp: true
76+
source: Azure AD
77+
sourcetype: azure:monitor:aad
78+
update_timestamp: true
Lines changed: 31 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
name: Azure AD Service Principal New Client Credentials
22
id: e3adc0d3-9e4b-4b5d-b662-12cec1adff2a
3-
version: 2
4-
date: '2022-08-17'
5-
author: Mauricio Velazco, Gowthamaraj Rajendran, Splunk
3+
version: 3
4+
date: '2024-06-25'
5+
author: Mauricio Velazco, Gowthamaraj Rajendran, Dean Luxton, Splunk
66
status: production
77
type: TTP
88
description: The following analytic identifies the addition of new credentials for Service
@@ -15,15 +15,27 @@ description: The following analytic identifies the addition of new credentials f
1515
instances within the Azure environment. By compromising an account who is an Owner of an application
1616
with privileged access, attackers may also escalate their privileges in an Azure AD environment by adding new credentials and
1717
logging in as the service principal.
18-
data_source: []
19-
search: ' `azuread` category=AuditLogs operationName="Update application*Certificates
20-
and secrets management " | rename * as * | rename properties.* as * | rename
21-
targetResources{}.* as * | stats values(displayName) as displayName by _time, initiatedBy.user.userPrincipalName,
22-
modifiedProperties{}.newValue | `azure_ad_service_principal_new_client_credentials_filter`'
18+
data_source:
19+
- Azure Active Directory
20+
search: ' `azure_monitor_aad` category=AuditLogs operationName="Update application*Certificates and secrets management "
21+
| rename properties.* as *
22+
| rename targetResources{}.* as *
23+
| rename modifiedProperties{}.* as *
24+
| eval src_user=coalesce(user,identity), newValue=mvfilter(newValue!="\"KeyDescription\"")
25+
| stats count min(_time) as firstTime max(_time) as lastTime values(displayName) as displayName values(src_ip) as src_ip values(eval(mvfilter(oldValue!="null"))) as oldValue by src_user, object, newValue
26+
| spath input=oldValue output=oldValues path={}
27+
| spath input=newValue output=newValues path={}
28+
| mvexpand newValues
29+
| where NOT newValues IN (oldValues)
30+
| fields - newValue, oldValue, oldValues
31+
| rename newValues as newValue
32+
| `security_content_ctime(firstTime)`
33+
| `security_content_ctime(lastTime)`
34+
| `azure_ad_service_principal_new_client_credentials_filter`'
2335
how_to_implement: You must install the latest version of Splunk Add-on for Microsoft
2436
Cloud Services from Splunkbase (https://splunkbase.splunk.com/app/3110/#/details).
2537
You must be ingesting Azure Active Directory events into your Splunk environment.
26-
Specifically, this analytic leverages the SignInLogs log category.
38+
This analytic was written to be used with the azure:monitor:aad sourcetype leveraging the Signin log category.
2739
known_false_positives: Service Principal client credential modifications may be part
2840
of legitimate administrative operations. Filter as needed.
2941
references:
@@ -37,22 +49,23 @@ tags:
3749
analytic_story:
3850
- Azure Active Directory Persistence
3951
- Azure Active Directory Privilege Escalation
52+
- NOBELIUM Group
4053
asset_type: Azure Active Directory
4154
confidence: 50
4255
impact: 70
43-
message: New credentials added for Service Principal $properties.targetResources{}.displayName$
56+
message: New credentials Service Principal credentials were added to $object$ by $src_user$
4457
mitre_attack_id:
4558
- T1098
4659
- T1098.001
4760
observable:
48-
- name: displayName
61+
- name: src_user
4962
type: User
5063
role:
5164
- Victim
52-
- name: initiatedBy.user.userPrincipalName
65+
- name: object
5366
type: User
5467
role:
55-
- Attacker
68+
- Victim
5669
product:
5770
- Splunk Enterprise
5871
- Splunk Enterprise Security
@@ -61,15 +74,16 @@ tags:
6174
- _time
6275
- category
6376
- operationName
64-
- properties.initiatedBy.user.userPrincipalName
77+
- user
6578
- properties.targetResources{}.displayName
6679
- properties.targetResources{}.modifiedProperties{}.newValue
80+
- src_ip
6781
risk_score: 35
6882
security_domain: threat
6983
tests:
7084
- name: True Positive Test
7185
attack_data:
7286
- data: https://media.githubusercontent.com/media/splunk/attack_data/master/datasets/attack_techniques/T1098.001/azure_ad_service_principal_credentials/azure-audit.log
73-
source: mscs:azure:eventhub
74-
sourcetype: mscs:azure:eventhub
75-
update_timestamp: true
87+
source: Azure AD
88+
sourcetype: azure:monitor:aad
89+
update_timestamp: true

0 commit comments

Comments
 (0)