I have an app service and in the Configuration section there is a connection string that connect to a database as follows:
Server=tcp:myserver.database.windows.net,1433;Database=myDataBase;User
ID=mylogin@myserver;Password=myPassword;Trusted_Connection=False;Encrypt=True;
How can I hide the plain text password utilizing Azure services or anything else?
2
Answers
Azure Key Vault is a good way to hide credentials in connection strings in an Azure Web App. Here’s an overview of the steps you can follow:
Vault.
Vault.
Vault at runtime.
As a general approach: Use Key Vault-referenced App Settings in Azure App Service.
Your preferred way, however, should be to use Managed Identity of the App Service and then use Azure AD-based authentication for all services which support it (Azure SQL does).