Skip to main content
Five Steps for Cloud Compliance Readiness·A practical playbook for security teamsDownload
CIS Microsoft Azure Foundations v6.0.0 · 5.4

No custom role should grant full administrator rights over a subscription

  • Level 1
  • Identity Services

This check looks for custom Azure roles whose permissions include every action (a wildcard) and that can be assigned at subscription scope. The safe setting is that no such role exists, and administrators use built-in roles or narrower custom roles instead.

Why it matters

A custom role that allows all actions on a subscription behaves like Owner, but sits outside the well-known built-in roles. It is easy to overlook in reviews, it may not show up in the lists people use to count administrators, and its permissions can be edited later without anyone noticing.

Microsoft's Azure role-based access control guidance recommends granting only the access people need, limiting the number of privileged assignments, and using built-in roles where possible. A wildcard custom role works against all three. See the sources below.

How to check it yourself

In the Azure portal open Subscriptions → your subscription → Access control (IAM) → Roles, filter Type to CustomRole, and open each role's JSON tab. Look for "*" in actions together with a subscription in assignableScopes.

Read-only with Azure PowerShell:

Get-AzRoleDefinition -Custom |
  Where-Object { $_.Actions -contains '*' } |
  Select-Object Name, Id, AssignableScopes

Or with the Azure CLI:

az role definition list --custom-role-only true \
  --query "[?contains(permissions[].actions[], '*')].{name:roleName, scopes:assignableScopes}" -o table

Any row returned is a role to review. These commands only read role definitions; run them with Reader access.

How to fix it

For each role found, first see who holds it: in Access control (IAM) → Role assignments filter by the role name. Move those people or groups to a fitting built-in role (Contributor, or a specific service role), or to a custom role that lists only the actions they need. Then delete the wildcard role.

Example, with the role name as a placeholder:

# Who has it?
az role assignment list --role "Example Full Admin" --all -o table

# After reassigning everyone, remove the role definition
az role definition delete --name "Example Full Admin"

An administrator runs these steps. ConfigCobra only needs Reader on the subscription, never writes to your Azure, and just shows the finding with suggested steps.

What changes when you fix it

Everyone assigned the role loses its permissions as soon as the assignment or definition is removed. If a person or an automation account such as a pipeline service principal relied on it, deployments and changes will start failing with authorization errors.

List the assignments first, including those on resource groups below the subscription and those held by service principals, and agree the replacement role with each owner. Do the switch in a maintenance window, add the new assignment before removing the old one, and test one deployment afterwards. Day-to-day users of the resources are not affected unless they were assigned the role themselves.

Included in

BenchmarkCIS IDProfile
CIS Microsoft Azure Foundations v6.0.05.4Level 1

Check this on your Microsoft Azure

ConfigCobra runs this check with every other control of the CIS Microsoft Azure Benchmarks, read-only.

Get in touch

Let's talk.

Whether you're evaluating ConfigCobra, running an audit, or managing a client fleet — we respond within one business day.

Free trial