Replacing a hardcoded Foundry key with keyless authentication

AI-901 Implement AI solutions by using Microsoft Foundry Medium Question 32 of 50

You are deploying a Python application in Azure that connects to Microsoft Foundry. The application currently authenticates by using a resource key hardcoded in configuration files. You need to configure keyless authentication so the application does not store or manage credentials in code.

Which authentication method should you use?

Show answer and explanation

DA managed identity with role-based access control

Using managed identities for Azure resources combined with Microsoft Entra authentication allows workloads running in Azure to authenticate to Microsoft Foundry without storing or managing credentials in application code or configuration files. Access is authorized by assigning the managed identity an Azure role-based access control role on the target resource. A service principal authenticates through Microsoft Entra ID but still requires managing and rotating a client secret or certificate in application configuration. Storing an API key in Azure Key Vault protects the key at rest but still requires the application to retrieve and present a static key credential. Shared access signatures provide delegated URI-based access for storage resources rather than keyless authentication.

Source: learn.microsoft.com/en-us/azure/ai-services/authentication

Anonymous, no account needed. Your tally stays in this browser.

Next question Start 5 timed questions Browse all 50 original AI-901 practice questions