Using Console
Using CLI
<role_name_or_id>
with the name or ID of the role you want to remove, and <service_principal_object_id>
with the object ID of the security service principal.
Repeat this command for each assumable role that needs to be remediated.
<service_principal_object_id>
with the object ID of the security service principal.
Ensure that the assumable roles you remediated are no longer listed.
Using Python
<your-subscription-id>
with your Azure subscription ID, and <your-scope>
with the appropriate scope (e.g., resource group, subscription, etc.) where the security services’ roles are assigned.Remember to handle any potential errors and exceptions that may occur during the remediation process.