Skip to content

Instantly share code, notes, and snippets.

@andrewmatveychuk
Created June 7, 2024 09:05
Show Gist options
  • Save andrewmatveychuk/772bf1699c2ef695c53e1bff791aabfb to your computer and use it in GitHub Desktop.
Save andrewmatveychuk/772bf1699c2ef695c53e1bff791aabfb to your computer and use it in GitHub Desktop.
Sample configuration in an appsettings.json file to authenticate to Azure resources using the ClientCertificateCredential type
{
"KeyVault": {
"vaultUri": "https://kv-4zdnwe1wgbwdp.vault.azure.net", // Your Key Vault URI
"tenantId": "3f5ed419-0e1b-4f47-8f94-a5b9fa4f298e", // Your Azure tenant ID
"clientId": "76a95e90-ec2c-4d59-b92b-9c5b8316cff4", // Your app registration in the tenant
"clientCertificate": "5378d04cd9a86a6cde595478d664cc9e2f755d4b", // That should be your unique certificate thumbprint
"clientCertificateStoreLocation": "LocalMachine" // The certificate store name, which should be 'CurrentUser' or 'LocalMachine'
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment