From 714b2c33df575f29395cabceeaaf26076aa39f3f Mon Sep 17 00:00:00 2001 From: Kristoffer Carlsson Date: Tue, 4 Sep 2018 09:20:34 -0400 Subject: [PATCH] use default proxy credentials when downloading via powershell (cherry picked from commit d495fed46606ff29685135bc63bffb5f7cc6d463) --- stdlib/Pkg/src/PlatformEngines.jl | 2 ++ 1 file changed, 2 insertions(+) diff --git a/stdlib/Pkg/src/PlatformEngines.jl b/stdlib/Pkg/src/PlatformEngines.jl index 8fb430d146be8..736ccccb0ea67 100644 --- a/stdlib/Pkg/src/PlatformEngines.jl +++ b/stdlib/Pkg/src/PlatformEngines.jl @@ -199,6 +199,8 @@ function probe_platform_engines!(;verbose::Bool = false) [System.Net.ServicePointManager]::SecurityProtocol = [System.Net.SecurityProtocolType]::Tls12; \$webclient = (New-Object System.Net.Webclient); + \$webclient.UseDefaultCredentials = \$true; + \$webclient.Proxy.Credentials = \$webclient.Credentials; \$webclient.Headers.Add("user-agent", \"Pkg.jl (https://github.com/JuliaLang/Pkg.jl)\"); \$webclient.DownloadFile(\"$url\", \"$path\") """