Skip to content
Cloud Governance Tools

Configure Azure AI Services resources to disable local key access

Configure Azure AI Services resources to disable local key access is an Azure guardrail written in Azure Policy. Deploys the setting that disables key access on Azure AI Services resources, leaving Microsoft Entra ID as the only access method. Copied from a licensed open source set and read on 10 Nov 2026.

More ai services guardrails ยท About Azure Policy

Built-in policy definition: Configure Azure AI Services resources to disable local key access (disable local authentication)
Definition ID: 55eff01b-f2bd-4c32-9203-db285f709d30
Category: Azure Ai Services
Supported effects: DeployIfNotExists, Disabled
policyRule (copied from the repository file):
{
    "if": {
      "field": "type",
      "equals": "Microsoft.CognitiveServices/accounts"
    },
    "then": {
      "effect": "[parameters('effect')]",
      "details": {
        "type": "Microsoft.CognitiveServices/accounts",
        "name": "[field('name')]",
        "existenceCondition": {
          "field": "Microsoft.CognitiveServices/accounts/disableLocalAuth",
          "equals": true
        },
        "roleDefinitionIds": [
          "/providers/Microsoft.Authorization/roleDefinitions/a001fd3d-188f-4b5d-821b-7da978bf7442",
          "/providers/microsoft.authorization/roleDefinitions/25fbc0a9-bd7c-42a3-aa1a-3b75d497ee68"
        ],
        "deployment": {
          "properties": {
            "mode": "incremental",
            "template": {
              "$schema": "http://schema.management.azure.com/schemas/2015-01-01/deploymentTemplate.json#",
              "contentVersion": "1.0.0.0",
              "parameters": {
                "resourceName": {
                  "type": "string"
                },
                "location": {
                  "type": "string"
                },
                "disableLocalAuth": {
                  "type": "string"
                },
                "kind": {
                  "type": "string"
                },
                "sku": {
                  "type": "object"
                },
                "publicNetworkAccess": {
                  "type": "string"
                },
                "networkAcls": {
                  "type": "object"
                }
              },
              "variables": {},
              "resources": [
                {
                  "type": "Microsoft.CognitiveServices/accounts",
                  "apiVersion": "2023-10-01-preview",
                  "name": "[parameters('resourceName')]",
                  "kind": "[parameters('kind')]",
                  "sku": "[parameters('sku')]",
                  "location": "[parameters('location')]",
                  "properties": {
                    "customSubDomainName": "[parameters('resourceName')]",
                    "disableLocalAuth": "[parameters('disableLocalAuth')]",
                    "publicNetworkAccess": "[parameters('publicNetworkAccess')]",
                    "networkAcls": "[parameters('networkAcls')]"
                  }
                }
              ],
              "outputs": {}
            },
            "parameters": {
              "location": {
                "value": "[field('location')]"
              },
              "resourceName": {
                "value": "[field('name')]"
              },
              "disableLocalAuth": {
                "value": "[parameters('disableLocalAuth')]"
              },
              "kind": {
                "value": "[field('kind')]"
              },
              "sku": {
                "value": "[field('Microsoft.CognitiveServices/accounts/sku')]"
              },
              "publicNetworkAccess": {
                "value": "[parameters('publicNetworkAccess')]"
              },
              "networkAcls": {
                "value": "[field('Microsoft.CognitiveServices/accounts/networkAcls')]"
              }
            }
          }
        }
      }
    }
  }
Blocks
Deploys the setting that disables key access on Azure AI Services resources, leaving Microsoft Entra ID as the only access method.
Breaks
Azure OpenAI Studio requires key access and will not function if key access is disabled, per the definition description. (source)
Test before applying
As for every Azure Policy guardrail: how to test before enforcing
Mechanism
Azure Policy (built-in definitions): Resources at the scope of the assignment (management group, subscription, resource group) and their children, except notScopes and exemptions
Taken from
open source set, MIT License, Azure/azure-policy repository, https://raw.githubusercontent.com/Azure/azure-policy/master/LICENSE

What the source says

"Key access (local authentication) is recommended to be disabled for security." (read 10 Nov 2026).

On what it breaks: "Azure OpenAI Studio, typically used in development/testing, requires key access and will not function if key access is disabled."

Sources

  1. Configure Azure AI Services resources to disable local key access, read 10 Nov 2026
  2. How to test it first, read 10 Nov 2026

Last reviewed 16 Nov 2026.