From: Peter Müller Date: Sat, 11 Apr 2020 10:19:20 +0000 (+0200) Subject: Pakfire: fix upstream proxy usage X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=d96d5db6e51999d1239639140ab715bf97cb2749;p=people%2Fms%2Fipfire-2.x.git Pakfire: fix upstream proxy usage This patch ensures Pakfire will download updates via the configured upstream proxy (if any) for both HTTP and HTTPS. Fixes: #12357 Signed-off-by: Peter Müller Signed-off-by: Arne Fitzenreiter --- diff --git a/src/pakfire/lib/functions.pl b/src/pakfire/lib/functions.pl index 45e3427b1c..17a420c33c 100644 --- a/src/pakfire/lib/functions.pl +++ b/src/pakfire/lib/functions.pl @@ -161,10 +161,10 @@ sub fetchfile { if ($proxysettings{'UPSTREAM_PROXY'}) { logger("DOWNLOAD INFO: Upstream proxy: \"$proxysettings{'UPSTREAM_PROXY'}\""); if ($proxysettings{'UPSTREAM_USER'}) { - $ua->proxy([["http", "https"] => "http://$proxysettings{'UPSTREAM_USER'}:$proxysettings{'UPSTREAM_PASSWORD'}@"."$proxysettings{'UPSTREAM_PROXY'}/"]); + $ua->proxy(["http", "https"], "http://$proxysettings{'UPSTREAM_USER'}:$proxysettings{'UPSTREAM_PASSWORD'}@"."$proxysettings{'UPSTREAM_PROXY'}/"); logger("DOWNLOAD INFO: Logging in with: \"$proxysettings{'UPSTREAM_USER'}\" - \"$proxysettings{'UPSTREAM_PASSWORD'}\""); } else { - $ua->proxy([["http", "https"] => "http://$proxysettings{'UPSTREAM_PROXY'}/"]); + $ua->proxy(["http", "https"], "http://$proxysettings{'UPSTREAM_PROXY'}/"); } }