After you have published the SCIM microservice app to Azure, run the following PowerShell script to assign Graph API permissions to the app service managed identity.
Set Graph API Permissions
Permissions follow the least-privilege principle and include the following:
Graph API / Permissions name | Access Granted by Permissions | Used By |
AuditLog.Read.All | Read audit log data | App Service Managed Identity |
Group.Read.All | Read group data | App Service Managed Identity |
GroupMember.ReadWrite.All | Read and write group memberships | App Service Managed Identity |
User.Read.All | Read user profile | App Service Managed Identity |
Reports.Read.All | Read report data | App Service Managed Identity |
Organization.Read.All | Read organization information | App Service Managed Identity |
Assign the App service to the owner role for the Tenant Root Group
In Azure, navigate to Management Groups and select the Tenant Root Group.
Select Access Control (IAM) from the Azure navbar and then click Add role assignment (Preview).
Select Owner and click Next.
For Assign access to select User, group, or service principal.
Click Select members and then search for and select the SCIM app service you created for the Azure AD SCIM microservice.
Click Select.
Review and assign the role assignment.
Assign the App service to the Global Admin role for the tenant
Navigate to Azure Active Directory and select Roles and administrators from the navbar.
Search for and select the Global Administrator role.
Click Add assignments and then search for and select the SCIM app service you created for the Azure AD SCIM microservice.
Click Add.
Error rendering macro 'excerpt-include' : No link could be created for 'IL:External Stylesheet - Test'.Set Azure REST API Permissions
If you are managing Azure roles in EmpowerID, in addition to setting the above permissions, you need to create a custom role in Azure and add the below permissions scoped to the appropriate Azure subscription(s) you want to manage in EmpowerID. These permissions allow EmpowerID to call the relevant Azure REST API endpoints needed to manage Azure roles.
Table 1: Permissions needed to manage Azure roles in EmpowerID
Azure REST API / Permissions name | Access Granted by Permissions | Used By |
Microsoft.ManagedIdentity/userAssignedIdentites/read | Gets an existing user assigned identity | App Service Managed Identity |
Microsoft.ManagedIdentity/userAssignedIdentites/write | Create a new user assigned identity or updates the tags associated with an existing user assigned identity | App Service Managed Identity |
Microsoft.ManagedIdentity/userAssignedIdentites/delete | Delete an existing user assigned identity | App Service Managed Identity |
Microsoft.Authorization/roleAssignments/read | Get information about a role assignment | App Service Managed Identity |
Microsoft.Authorization/roleAssignments/write | Create a role assignment at the specified scope | App Service Managed Identity |
Microsoft.Authorization/roleAssignments/delete | Delete a role assignment at the specified scope | |
Microsoft.Authorization/roleDefinitions/read | Get information about a role definition | App Service Managed Identity |
Microsoft.Authorization/roleDefinitions/write | Create or update a custom role definition with specified permissions and assignable scopes | App Service Managed Identity |
Microsoft.Authorization/roleDefinitions/delete | Delete the specified custom role definition | App Service Managed Identity |
Microsoft.Management/managementGroups/read | View management groups | App Service Managed Identity |
Microsoft.Resources/subscriptions/resourceGroups/read | Get resource groups | App Service Managed Identity |
Microsoft.Resources/subscriptions/resources/read | Gets resources of a subscription | App Service Managed Identity |
To set the Azure REST API Permissions for the target subscription, do the following:
In Azure, navigate to the target subscription and select Access control (IAM) from the Azure navbar.
On the Access Control (IAM) page, click Add and select Add custom role.
Under Basics, enter a Custom role name.
Select the Permissions tab and click Add permissions.
Search for Microsoft.ManagedIdentity and click the Microsoft Managed Identity tile.
For Actions, under Microsoft.ManagedIdentity/userAssignedIdentities, select the following:
Read : Get User Assigned Identity
Write : Create/Update User Assigned Identity
Delete : Delete User Assigned Identity
Click Add.
Back on the Create a custom role page, click Add permissions again and then search for Microsoft.Authorization.
Click the Microsoft Authorization tile and then add the below permissions:
Microsoft.Authorization/roleAssignments
Read : Get role assignment
Write : Create role assignment
Delete : Delete role assignment
Microsoft.Authorization/roleDefinitions
Read : Get role definition
Write : Create or update custom role definition
Delete : Delete custom role definition
Click Add.
Back on the Create a custom role page, click Add permissions again and then search for Microsoft.Authorization.
Click the Microsoft Management tile and select Read : List Groups under Microsoft.Management/managementGroups.
Click Add.
Back on the Create a custom role page, click Add permissions again and then search for Microsoft.Resources.
Click the Microsoft Resources tile and then select the following permissions:
Microsoft.Resources/subscriptions/resourcegroups
Read : Get Resource Group
Microsoft.Resources/subscriptions/resources
Read : Get Subscription Resources
Click Add.
Back on the Create a custom role page, select the Assignable scopes tab and verify the scope.
Click Review + Create.
Review the permissions and then click Create.
Click OK to close the “created custom role” message.
Now that you have created the custom role with the needed permissions, you need to assign the Azure AD SCIM microservice to the role.On the Access control (IAM) page, click Add > Add role assignment.
In the Add role assignment pane that appears, enter the following:
Role – Select the custom role you just created
Assign access to – App Service
Subscription – Target subscription
Select – The SCIM app service you created earlier.
Click Save to add the role assignment.
On the Access control (IAM) page, select the Role assignments tab. You should see the SCIM app service you created assigned to the custom role.