Skip to content

Instantly share code, notes, and snippets.

@giseongeom
Last active June 5, 2018 15:11
Show Gist options
  • Select an option

  • Save giseongeom/e2a039858f6c396df4985eab4170882a to your computer and use it in GitHub Desktop.

Select an option

Save giseongeom/e2a039858f6c396df4985eab4170882a to your computer and use it in GitHub Desktop.
Enable TLS 1.2 support on Powershell 5.1
# Enable tls1.2 from default (Ssl3, Tls)
# https://powershell.org/forums/topic/is-it-possible-to-enable-tls-1-2-as-default-in-powershell/
# https://www.codyhosterman.com/2016/06/force-the-invoke-restmethod-powershell-cmdlet-to-use-tls-1-2/
# https://developercommunity.visualstudio.com/content/problem/201457/unable-to-connect-to-github-due-to-tls-12-only-cha.html
# https://githubengineering.com/crypto-removal-notice/
[Net.ServicePointManager]::SecurityProtocol = `
[Net.SecurityProtocolType]::Ssl3 -bor `
[Net.SecurityProtocolType]::Tls -bor `
[Net.SecurityProtocolType]::Tls11 -bor `
[Net.SecurityProtocolType]::Tls12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment