Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add command to set the Powershell TLS version before downloading #9

Merged
merged 1 commit into from
May 31, 2018

Conversation

ph
Copy link
Contributor

@ph ph commented May 10, 2018

By default poweshell at least on windows 2012 default to TLS1.0, github
requires TLS1.2 so we have to change the value before downloading the
executable.

By default poweshell at least on windows 2012 default to TLS1.0, github
requires TLS1.2 so we have to change the value before downloading the
executable.
Copy link
Owner

@andrewkroh andrewkroh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. Will test it out. Thanks

@ph
Copy link
Contributor Author

ph commented May 11, 2018

@andrewkroh if you remove the line in this PR elastic/beats#7073 you will get the following error:

    win2012: Invoke-WebRequest : The request was aborted: Could not create SSL/TLS secure
    win2012: channel.
    win2012: At C:\tmp\vagrant-shell.ps1:7 char:1
    win2012: + Invoke-WebRequest -URI
    win2012: https://github.com/andrewkroh/gvm/releases/download/v0.0. ...
    win2012: + ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    win2012: ~~~
    win2012:     + CategoryInfo          : InvalidOperation: (System.Net.HttpWebRequest:Htt
    win2012:    pWebRequest) [Invoke-WebRequest], WebException
    win2012:     + FullyQualifiedErrorId : WebCmdletWebResponseException,Microsoft.PowerShe
    win2012:    ll.Commands.InvokeWebRequestCommand
    win2012: C:WindowsSystem32gvm.exe : The term 'C:WindowsSystem32gvm.exe' is not
    win2012: recognized as the name of a cmdlet, function, script file, or operable
    win2012: program. Check the spelling of the name, or if a path was included, verify
    win2012: that the path is correct and try again.
    win2012: At C:\tmp\vagrant-shell.ps1:8 char:1
    win2012: + C:WindowsSystem32gvm.exe --format=powershell 1.10.1 | Invoke-Expression
    win2012: + ~~~~~~~~~~~~~~~~~~~~~~~~
    win2012:     + CategoryInfo          : ObjectNotFound: (C:WindowsSystem32gvm.exe:String
    win2012:    ) [], CommandNotFoundException
    win2012:     + FullyQualifiedErrorId : CommandNotFoundException

@andrewkroh andrewkroh merged commit 710fa73 into andrewkroh:master May 31, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants