question

azure-7678 avatar image
0 Votes"
azure-7678 asked sikumars commented

add azure client certificate to client rest api headers c#

i am retrieving the certificate from azure which is added in azurekeyvault trying to add that to my rest api headers getting an error ssl connection cannot established. please help me how to add certificate to rest api headers.



105029-image.png


dotnet-csharpazure-key-vault
image.png (80.0 KiB)
· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

Thanks for reaching out.

Could you please share detailed inner exception? also if possible try to use PowerShell Invoke-RestMethod or Postman way to add certificate to rest api headers which received from Keyvault this would help us isolate the issue. Thanks.

Example:

Powershell
Invoke-RestMethod -Method Get -Uri <API url> -Headers <header_value>
Invoke-RestMethod -Method Post -Uri <API url> -Body <header_value>

PostMan:
https://learning.postman.com/docs/sending-requests/requests/#selecting-request-methods

0 Votes 0 ·

Just checking in to see if the above answer helped. If this answers your query, please don’t forget to click "Accept the answer" and Up-Vote for the same, which might be beneficial to other community members reading this thread. And, if you have any further query do let us know.
Thanks,

0 Votes 0 ·

0 Answers