Today, I needed to force an Invoke-WebRequest command to use TLS 1.2 to test access to Azure Key Vault. I ran the command below to force it:
[Net.ServicePointManager]::SecurityProtocol =[Net.SecurityProtocolType]::Tls12
And, here's the Invoke-WebRequest command I was using for testing:
$(Invoke-WebRequest -UseBasicParsing -Uri https://your-key-vault-name/healthstatus).Headers
No comments:
Post a Comment