I am going use key vault for Azure Function App.
I am using .NET SDK.
Example:
string keyVaultUrl = configuration["KeyVaultSettings:Url"];
TokenCredential credential = new DefaultAzureCredential();
#if DEBUG
credential = new ClientSecretCredential(configuration["AZURE_TENANT_ID"],
configuration["AZURE_CLIENT_ID"],
configuration["AZURE_CLIENT_SECRET"]);
#endif
var secretClient = new SecretClient(new Uri(keyVaultUrl), credential);
To debug locally I need
tenant_id, client_id, and client_secret.
How Can i get this?
I assume you have Authentication turned on in your Function App. Go to App Registration of the function app and for steps to fetch Client Id
, Tenant Id
and Client Secret
, you can refer to this and this