Azure AD Guest User Type Changed To Member
Description
The following analytic detects when an Azure AD guest user account has its UserType property changed from Guest to Member. It leverages Azure Active Directory AuditLogs for the "Update user" operation and compares the UserType modifiedProperty old and new values. A legacy account whose UserType was null is not a guest promotion and does not match. Guest accounts carry inherent restrictions on tenant resource access; elevating to Member removes those restrictions. If confirmed malicious, this activity indicates an attacker is expanding the capabilities of a compromised or attacker-controlled guest account to gain broader access to tenant resources.
Query · spl
`azure_monitor_aad`
category=AuditLogs
operationName="Update user"
properties.targetResources{}.modifiedProperties{}.displayName="UserType"
properties.targetResources{}.modifiedProperties{}.oldValue=*Guest*
properties.targetResources{}.modifiedProperties{}.newValue=*Member*
| rename properties.* as *
| rename initiatedBy.user.userPrincipalName as initiatedBy
| rename initiatedBy.app.displayName as initiatedByApp
| eval actor = coalesce(initiatedBy, initiatedByApp)
| rename targetResources{}.userPrincipalName as targetUser
| rename userAgent as user_agent
| eval index_number = mvfind('targetResources{}.modifiedProperties{}.displayName', "UserType")
| eval oldUserType = mvindex('targetResources{}.modifiedProperties{}.oldValue', index_number)
| eval newUserType = mvindex('targetResources{}.modifiedProperties{}.newValue', index_number)
| search oldUserType="*Guest*" newUserType="*Member*"
| fillnull value="unknown" dest src vendor_account vendor_product user_agent actor targetUser oldUserType newUserType signature
| stats count min(_time) as firstTime
max(_time) as lastTime
BY dest src vendor_account vendor_product user_agent
actor targetUser oldUserType newUserType signature
| rename actor as user
| `security_content_ctime(firstTime)`
| `security_content_ctime(lastTime)`
| `azure_ad_guest_user_type_changed_to_member_filter`
Implementation guide
You must install the latest version of Splunk Add-on for Microsoft Cloud Services from Splunkbase (https://splunkbase.splunk.com/app/3110/#/details). You must be ingesting Azure Active Directory events into your Splunk environment through an EventHub. This analytic was written to be used with the azure:monitor:aad sourcetype leveraging the AuditLogs log category.
Known false positives
- Legitimate conversion of a guest account to a member account can occur when a contractor becomes a full-time employee or when an organization consolidates external identities. Validate the actor, target user, and whether a change management record exists for the conversion.
Analyst notes
Known false positives: Legitimate conversion of a guest account to a member account can occur when a contractor becomes a full-time employee or when an organization consolidates external identities. Validate the actor, target user, and whether a change management record exists for the conversion.