1.23 Ensure Custom Role is assigned for Administering Resource Locks - Permissions

Information

Resource locking is a powerful protection mechanism that can prevent inadvertent modification/deletion of resources within Azure subscriptions/Resource Groups and is a recommended NIST configuration.

Rationale:

Given the resource lock functionality is outside of standard Role Based Access Control(RBAC), it would be prudent to create a resource lock administrator role to prevent inadvertent unlocking of resources.

Impact:

By adding this role is you can have specific permissions granted for managing just resource locks rather than needing to provide the wide owner or contributor role reducing the risk of the user being able to do unintentional damage.

NOTE: Nessus has provided the target output to assist in reviewing the benchmark to ensure target compliance.

Solution

From Azure Console

In the Azure portal, open a subscription or resource group where you want the custom role to be assignable.

Select Access control (IAM)

Click Add

Select Add custom role'.

In the Custom Role Name field enter Resource Lock Administrator

In the Description field enter Can Administer Resource Locks

For Baseline permissions select Start from scratch

Click next

In the Permissions tab select Add permissions

in the Search for a permission box, type in Microsoft.Authorization/locks to search for permissions.

Select the check box next to the permission called Microsoft.Authorization/locks

click add

Click Review+create

Click Create

Assign the newly created role to the appropriate user.
Using PowerShell:
Below is a power shell definition for a resource lock administrator role created at an Azure Management group level

Import-Module Az.Accounts
Connect-AzAccount

$role = Get-AzRoleDefinition 'User Access Administrator'
$role.Id = $null
$role.Name = 'Resource Lock Administrator'
$role.Description = 'Can Administer Resource Locks'
$role.Actions.Clear()
$role.Actions.Add('Microsoft.Authorization/locks/*')
$role.AssignableScopes.Clear()

* Scope at the Management group level Management group

$role.AssignableScopes.Add('/providers/Microsoft.Management/managementGroups/MG-Name')

New-AzRoleDefinition -Role $role
Get-AzureRmRoleDefinition 'Resource Lock Administrator'

See Also

https://workbench.cisecurity.org/files/3459

Item Details

Category: ACCESS CONTROL, MEDIA PROTECTION

References: 800-53|AC-3, 800-53|MP-2, CSCv7|14.6

Plugin: microsoft_azure

Control ID: 0283910bf77680b4e8338bc2ef9d1c82c0b9d0929a384222077895f16599c1bd