azureblog.co.uk
← cd ~/roles
// roles/entra

Attribute Assignment AdministratorMicrosoft Entra built-in role

Assign custom security attribute keys and values to supported Microsoft Entra objects.

Role ID58a13ea3-c632-46ae-9ee0-9c0d43cd7f3d
PrivilegedNo
Permissions10

What it can do

PermissionWhat it allows
microsoft.directory/attributeSets/allProperties/readRead all properties of attribute sets
microsoft.directory/azureManagedIdentities/customSecurityAttributes/readRead custom security attribute values for Microsoft Entra managed identities
microsoft.directory/azureManagedIdentities/customSecurityAttributes/updateUpdate custom security attribute values for Microsoft Entra managed identities
microsoft.directory/customSecurityAttributeDefinitions/allProperties/readRead all properties of custom security attribute definitions
microsoft.directory/devices/customSecurityAttributes/readRead custom security attribute values for devices
microsoft.directory/devices/customSecurityAttributes/updateUpdate custom security attribute values for devices
microsoft.directory/servicePrincipals/customSecurityAttributes/readRead custom security attribute values for service principals
microsoft.directory/servicePrincipals/customSecurityAttributes/updateUpdate custom security attribute values for service principals
microsoft.directory/users/customSecurityAttributes/readRead custom security attribute values for users
microsoft.directory/users/customSecurityAttributes/updateUpdate custom security attribute values for users

Assign it

The role ID is the same in every tenant, so these work as they are. Make it eligible through PIM:

powershell13 lines
Connect-MgGraph -Scopes "RoleEligibilitySchedule.ReadWrite.Directory"
$user = Get-MgUser -UserId "jane.doe@contoso.com"
New-MgRoleManagementDirectoryRoleEligibilityScheduleRequest -BodyParameter @{
    Action           = "AdminAssign"
    Justification    = "Needs Attribute Assignment Administrator for <reason>"
    RoleDefinitionId = "58a13ea3-c632-46ae-9ee0-9c0d43cd7f3d"
    DirectoryScopeId = "/"
    PrincipalId      = $user.Id
    ScheduleInfo     = @{
        StartDateTime = (Get-Date).ToUniversalTime().ToString("o")
        Expiration    = @{ Type = "afterDuration"; Duration = "P180D" }
    }
}

Who already has it?

powershell3 lines
Connect-MgGraph -Scopes "RoleManagement.Read.Directory"
Get-MgRoleManagementDirectoryRoleAssignment -Filter "roleDefinitionId eq '58a13ea3-c632-46ae-9ee0-9c0d43cd7f3d'" -ExpandProperty Principal |
    ForEach-Object { $_.Principal.AdditionalProperties.displayName }

Related roles

Find the smallest role for a task →