Control: 5.12 Ensure that 'User consent for applications' is set to 'Do not allow user consent'
Description
Require administrators to provide consent for applications before use.
If Microsoft Entra ID is running as an identity provider for third-party applications, permissions and consent should be limited to administrators or pre-approved. Malicious applications may attempt to exfiltrate data or abuse privileged user accounts.
Remediation
Remediate from Azure Portal
- From Azure Home select the Portal Menu.
- Select
Microsoft Entra ID. - Under
Manage, selectEnterprise applications. - Under
Security, selectConsent and permissions. - Under
Manage, selectUser consent settings. - Set
User consent for applicationstoDo not allow user consent. - Click
Save.
Default Value
By default, Users consent for applications is set to Allow user consent for apps.
Usage
Run the control in your terminal:
powerpipe control run azure_compliance.control.cis_v500_5_12Snapshot and share results via Turbot Pipes:
powerpipe loginpowerpipe control run azure_compliance.control.cis_v500_5_12 --shareSQL
This control uses a named query:
with distinct_tenant as ( select distinct tenant_id, display_name, subscription_id, _ctx from azure_tenant)select id as resource, case when exists ( select 1 from jsonb_array_elements_text( (default_user_role_permissions -> 'permissionGrantPoliciesAssigned')::jsonb ) as pol(val) where val like 'ManagePermissionGrantsForSelf.%' ) then 'alarm' else 'ok' end as status, case when exists ( select 1 from jsonb_array_elements_text( (default_user_role_permissions -> 'permissionGrantPoliciesAssigned')::jsonb ) as pol(val) where val like 'ManagePermissionGrantsForSelf.%' ) then t.display_name || ' user consent for applications allowed.' else t.display_name || ' user consent for applications disallowed.' end as reason, t.tenant_id from distinct_tenant as t, azuread_authorization_policy