Fix TLS errors when downloading stage0

This commit is contained in:
Dan Robertson 2018-11-12 02:32:21 -08:00
parent 775eab5883
commit c211238180
No known key found for this signature in database
GPG Key ID: 45C4A652C47E42A5
1 changed files with 2 additions and 2 deletions

View File

@ -79,8 +79,8 @@ def _download(path, url, probably_big, verbose, exception):
# see http://serverfault.com/questions/301128/how-to-download
if sys.platform == 'win32':
run(["PowerShell.exe", "/nologo", "-Command",
"(New-Object System.Net.WebClient)"
".DownloadFile('{}', '{}')".format(url, path)],
"[Net.ServicePointManager]::SecurityProtocol = [Net.SecurityProtocolType]::Tls12;",
"(New-Object System.Net.WebClient).DownloadFile('{}', '{}')".format(url, path)],
verbose=verbose,
exception=exception)
else: