You are configuring an Azure App Service web app to securely retrieve database credentials from an Azure Key Vault. The solution must use a system-assigned managed identity to access the Key Vault without storing any credentials in the application code or settings.
Which two configuration steps should you perform?
- Enable a system-assigned managed identity for the App Service web app.Cevap
- Create an access policy in the Key Vault that grants the web app's identity Secret Get permissions.Cevap
- CEnable a user-assigned managed identity on the Key Vault.
- DCreate an application setting in the web app that uses the @Microsoft.KeyVaultSecret(SecretUri=...) syntax.
Cevap
Enable a system-assigned managed identity for the App Service web app, and create an access policy in the Key Vault that grants the web app's identity Secret Get permissions.
To retrieve secrets securely, you must first enable a system-assigned managed identity on the App Service web app so it can authenticate to Azure resources. Second, you must authorize this identity in the Key Vault by creating an access policy that grants it Get permissions on secrets.
Adım Adım Çözüm
Anahtar Kavram
Configuring Azure App Service to securely access Key Vault secrets using managed identities