my iwr is getting error

Davi Ramon 0 Reputation points
2023-06-02T13:16:33.3133333+00:00

my iwr is getting error here is im getting

iwr : The request was aborted: Unable to create a secure channel for SSL/TLS.
On line: 1 character: 2
+ iwr -useb get.scoop.sh | iex
+ ~~~~~~~~~~~~~~~~~~~~~~
     + CategoryInfo : InvalidOperation: (System.Net.HttpWebRequest:HttpWebRequest) [Invoke-WebRequest], WebExc
    option
     + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShell.Commands.InvokeWebRequestCommand
Windows for business | Windows Client for IT Pros | User experience | Other
{count} votes

1 answer

Sort by: Most helpful
  1. Limitless Technology 44,751 Reputation points
    2023-06-05T10:15:29.5833333+00:00

    Hello

    Thank you for your question and reaching out.

    The error's may cause due to Powershell connects to websites by default using TLS 1.0, while TLS 1.2 is required for website security. Running any of the commands listed below will cause this behaviour to alter to utilise all protocols. Additionally, you can specify a single protocol.

    [Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls, [Net.SecurityProtocolType]::Tls11, [Net.SecurityProtocolType]::Tls12, [Net.SecurityProtocolType]::Ssl3

    [Net.ServicePointManager]::SecurityProtocol = "Tls, Tls11, Tls12, Ssl3"

    --If the reply is helpful, please Upvote and Accept as answer--

    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.