I am using the latest version 8.8.0 with Angular and .NET Core. I am follllowing your teams article :** https://volosoft.com/blog/Using-Azure-Key-Vault-with-ASP.NET-Core** I have carried out all steps as mentioned and also uploaded the certificate. But when i run the project i am getting the "System.InvalidOperationException: 'Sequence contains no elements'" error in AppAzureKeyVaultConfigurer.cs file. Seems the code is not able to find the uploaded certificate which exists with the registered app on Azure.
Is there any point i have missed because with the managed service it works perfectly. But not with certificate.
Thanks.
3 Answer(s)
-
0
I got this working. There were some steps involved in creating the certificate the right way.
Thanks
-
0
Anything specific others like myself should be aware of?
Thanks!
-
0
Yes. Two things.
- Generate a certificate (.PFX) with a private and public key using a tool like OpenSSL.
- Upload public key (.pem) to the registered app in the Azure portal
- Right-click .PFX certificate and install it in personal folder on your machine.
I was getting the above error since my exported certificate from certmgr could not have a private key. This wasted lot of time for me to figure out.😊