问题
Do you know if there is a way to enable TLS1.2 in powershell (ie. for invoke-webrequest or invoke-restmethod)?
By default it looks like Powershell uses TLS1.0, which is not compatible with all our web services.
/Patrik
回答1:
There was!
[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12
/Patrik
来源:https://stackoverflow.com/questions/33594137/powershell-tls1-2-support