From mboxrd@z Thu Jan 1 00:00:00 1970 From: Ian Jackson Subject: Re: [OSSTEST v6 01/24] TestSupport: Add helper to fetch a URL on a host Date: Tue, 12 May 2015 16:08:46 +0100 Message-ID: <21842.6014.310276.267459@mariner.uk.xensource.com> References: <1430905605.2660.187.camel@citrix.com> <1430906213-30108-1-git-send-email-ian.campbell@citrix.com> Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: <1430906213-30108-1-git-send-email-ian.campbell@citrix.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xen.org Errors-To: xen-devel-bounces@lists.xen.org To: Ian Campbell Cc: xen-devel@lists.xen.org List-Id: xen-devel@lists.xenproject.org Ian Campbell writes ("[OSSTEST v6 01/24] TestSupport: Add helper to fetch a URL on a host"): > Signed-off-by: Ian Campbell > +sub target_fetchurl($$$;$) { > + my ($ho, $url, $path, $timeo) = @_; > + $timeo ||= 2000; > + my $useproxy = "export http_proxy=$c{HttpProxy};" if $c{HttpProxy}; > + target_cmd_root($ho, "$useproxy wget --progress=dot:mega -O $path $url", $timeo); Do we care that this will break badly if the url contains shell metacharacters ? I think we may do. Ian.