Gallery › SQL › Azure built-in policies
Azure SQL Managed Instance should have Microsoft Entra-only authentication
Converted Initiative Version 1.0.0
Require Microsoft Entra-only authentication for Azure SQL Managed instance, disabling local authentication methods. This allows access exclusively via Microsoft Entra identities, enhancing security with modern authentication enhancements including MFA, SSO, and secret-less programmatic access with managed identities.
ConvertTo-Bylaw converted this initiative, and proved that the file compiles back to the same definition.
Azure Policy JSONSqlManagedInstance_ADOnlyEnforcement_Deny.json · 54 lines
{
"properties": {
"displayName": "Azure SQL Managed Instance should have Microsoft Entra-only authentication",
"policyType": "BuiltIn",
"description": "Require Microsoft Entra-only authentication for Azure SQL Managed instance, disabling local authentication methods. This allows access exclusively via Microsoft Entra identities, enhancing security with modern authentication enhancements including MFA, SSO, and secret-less programmatic access with managed identities.",
"metadata": {
"version": "1.0.0",
"category": "SQL"
},
"Version": "1.0.0",
"parameters": {
"effect": {
"type": "String",
"metadata": {
"displayName": "Effect",
"description": "Enable or disable the execution of the policy"
},
"allowedValues": [
"Audit",
"Deny",
"Disabled"
],
"defaultValue": "Audit"
}
},
"policyDefinitions": [
{
"policyDefinitionReferenceId": "SqlManagedInstance_Creation_ADOnlyEnabled",
"policyDefinitionId": "/providers/Microsoft.Authorization/policyDefinitions/78215662-041e-49ed-a9dd-5385911b3a1f",
"definitionVersion": "1.*.*",
"parameters": {
"effect": {
"value": "[parameters('effect')]"
}
}
},
{
"policyDefinitionReferenceId": "SqlManagedInstance_ADOnlyEnabled_DisableADAuth",
"policyDefinitionId": "/providers/Microsoft.Authorization/policyDefinitions/0c28c3fb-c244-42d5-a9bf-f35f2999577b",
"definitionVersion": "1.*.*",
"parameters": {
"effect": {
"value": "[parameters('effect')]"
}
}
}
],
"versions": [
"1.0.0"
]
},
"id": "/providers/Microsoft.Authorization/policySetDefinitions/9b8d8228-e8cc-4c95-8d98-47f32df40b5e",
"name": "9b8d8228-e8cc-4c95-8d98-47f32df40b5e"
}Bylaw9b8d8228-e8cc-4c95-8d98-47f32df40b5e.bylaw.ps1 · 36 lines
# Converted from SqlManagedInstance_ADOnlyEnforcement_Deny.json by ConvertTo-Bylaw.
Initiative '9b8d8228-e8cc-4c95-8d98-47f32df40b5e' {
Properties @{
DisplayName = 'Azure SQL Managed Instance should have Microsoft Entra-only authentication'
Description = 'Require Microsoft Entra-only authentication for Azure SQL Managed instance, disabling local authentication methods. This allows access exclusively via Microsoft Entra identities, enhancing security with modern authentication enhancements including MFA, SSO, and secret-less programmatic access with managed identities.'
Version = '1.0.0'
Category = 'SQL'
PolicyVersion = '1.0.0'
}
Parameter Effect @{
AllowedValues = @('Audit', 'Deny', 'Disabled')
Default = 'Audit'
DisplayName = 'Effect'
Description = 'Enable or disable the execution of the policy'
}
PolicyDefinition @{
Id = '78215662-041e-49ed-a9dd-5385911b3a1f'
ReferenceId = 'SqlManagedInstance_Creation_ADOnlyEnabled'
Version = '1.*.*'
Parameters = @{
effect = (Param Effect)
}
}
PolicyDefinition @{
Id = '0c28c3fb-c244-42d5-a9bf-f35f2999577b'
ReferenceId = 'SqlManagedInstance_ADOnlyEnabled_DisableADAuth'
Version = '1.*.*'
Parameters = @{
effect = (Param Effect)
}
}
}Members (2)
- Azure SQL Managed Instances should have Microsoft Entra-only authentication enabled during creation
- Azure SQL Managed Instance should have Microsoft Entra-only authentication enabled
Source: built-in-policies/policySetDefinitions/SQL/SqlManagedInstance_ADOnlyEnforcement_Deny.json in Azure/azure-policy, under the MIT licence.
Bylaw