X-Git-Url: https://git.exim.org/buildfarm-client.git/blobdiff_plain/a475ae642a475267249caa9d561380e2baccf5d9..b04f6889700e04f6a9d6ce14c7b29d86ec33d8e9:/EximBuild/WebTxn.pm diff --git a/EximBuild/WebTxn.pm b/EximBuild/WebTxn.pm index f71f55a..1605fb9 100644 --- a/EximBuild/WebTxn.pm +++ b/EximBuild/WebTxn.pm @@ -8,12 +8,13 @@ See accompanying License file for license details Most of this code is imported from the older standalone script run_web_txn.pl -which is now just a shell that calls the function below. It is now only +which is now just a shell that calls the function below. It is now only needed on older Msys installations (i.e. things running perl < 5.8). -=cut +=cut use strict; +use URI::Escape; use vars qw($VERSION); $VERSION = 'REL_0.1'; @@ -99,9 +100,9 @@ sub run_web_txn my $content = "changed_files=$changed_this_run&" . "changed_since_success=$changed_since_success&" - ."branch=$branch&res=$status&stage=$stage&animal=$animal&ts=$ts" + . 'branch=' . uri_escape($branch) . "&res=$status&stage=$stage&animal=$animal&ts=$ts" ."&log=$log_data&conf=$confsum"; - my $sig= sha1_hex($content,$secret); + my $sig = sha1_hex($content,$secret); $content .= "&frozen_sconf=$frozen_sconf"; @@ -114,7 +115,9 @@ sub run_web_txn $ua->agent("Exim Build Farm Reporter"); if (my $proxy = $ENV{BF_PROXY}) { - $ua->proxy('http',$proxy); + # untested. Please notify hs@schlittermann.de, if you + # encounter any problem here: + $ua->proxy(URI->new($target)->scheme, $proxy); } my $request=HTTP::Request->new(POST => "$target/$sig");