[Bug 506568] [NEW] poldek prepends extra slash to urls when http_proxy is used

Elan Ruusamäe glen at delfi.ee
Tue Jan 12 19:55:31 CET 2010


Public bug reported:

poldek prepends extra slash to urls when http_proxy is used.

it fetches:
GET http://ftp1.pld-linux.org//dists/th/....rpm
must fetch:
GET http://ftp1.pld-linux.org/dists/th/....rpm

this breaks some setups of ftp mirrors.

to reproduce, find some http proxy, then use this code to test:

# rm -rf /tmp/test
# rpm -r /tmp/test --initdb
# poldek -r /tmp/test --fetch=/tmp/test -O 'proxy = http,ftp: http://proxy:3128/' -s http://ftp1.pld-linux.org/dists/th/PLD/x86_64/RPMS/ -u FHS -vv

Setting cache directory path to /var/cache/poldek
Enabling multilib mode, transaction color = 3
Loading [pndir]http://ftp1.pld-linux.org/dists/th/PLD/x86_64/RPMS/packages.ndir.gz...
  Loading directory index of http://ftp1.pld-linux.org/dists/th/PLD/x86_64/RPMS/packages.ndir.gz...
10921 packages read
Indexing...
Processing dependencies...
There are 1 package to install:
I FHS-2.3-29.x86_64
Retrieving http://ftp1.pld-linux.org//[...]/FHS-2.3-29.x86_64.rpm...
Connecting to proxy:3128...
< GET http://ftp1.pld-linux.org//dists/th/PLD/x86_64/RPMS/FHS-2.3-29.x86_64.rpm HTTP/1.1
<   Host: proxy
<   User-Agent: poldek-vhttp/0.30
> HTTP/1.0 200 OK
>   Date: Tue, 12 Jan 2010 18:49:33 GMT
>   Server: Apache/2.2.14 (Unix) mod_ssl/2.2.14 OpenSSL/0.9.8l
>   Last-Modified: Wed, 21 Oct 2009 18:37:30 GMT
>   ETag: "dfe9e5c2-9044-4767645794207"
>   Accept-Ranges: bytes
>   Content-Length: 36932
>   Content-Type: application/x-rpm
>   Age: 223
>   Connection: close
Total file size 36932, 36932 to download, mtime Wed Oct 21 18:37:30 2009

.............................. 100.0% [36.1K (36.1K/s)]
Closing /tmp/test/FHS-2.3-29.x86_64.rpm (mtime 2009-10-21 15:37:30)

** Affects: poldek
     Importance: Undecided
         Status: New

** Affects: pld-linux
     Importance: Undecided
         Status: New

** Also affects: poldek
   Importance: Undecided
       Status: New

-- 
poldek prepends extra slash to urls when http_proxy is used
https://bugs.launchpad.net/bugs/506568
You received this bug notification because you are subscribed to PLD
Linux.

Status in poldek: New
Status in PLD Linux Distribution: New

Bug description:
poldek prepends extra slash to urls when http_proxy is used.

it fetches:
GET http://ftp1.pld-linux.org//dists/th/....rpm
must fetch:
GET http://ftp1.pld-linux.org/dists/th/....rpm

this breaks some setups of ftp mirrors.

to reproduce, find some http proxy, then use this code to test:

# rm -rf /tmp/test
# rpm -r /tmp/test --initdb
# poldek -r /tmp/test --fetch=/tmp/test -O 'proxy = http,ftp: http://proxy:3128/' -s http://ftp1.pld-linux.org/dists/th/PLD/x86_64/RPMS/ -u FHS -vv

Setting cache directory path to /var/cache/poldek
Enabling multilib mode, transaction color = 3
Loading [pndir]http://ftp1.pld-linux.org/dists/th/PLD/x86_64/RPMS/packages.ndir.gz...
  Loading directory index of http://ftp1.pld-linux.org/dists/th/PLD/x86_64/RPMS/packages.ndir.gz...
10921 packages read
Indexing...
Processing dependencies...
There are 1 package to install:
I FHS-2.3-29.x86_64
Retrieving http://ftp1.pld-linux.org//[...]/FHS-2.3-29.x86_64.rpm...
Connecting to proxy:3128...
< GET http://ftp1.pld-linux.org//dists/th/PLD/x86_64/RPMS/FHS-2.3-29.x86_64.rpm HTTP/1.1
<   Host: proxy
<   User-Agent: poldek-vhttp/0.30
> HTTP/1.0 200 OK
>   Date: Tue, 12 Jan 2010 18:49:33 GMT
>   Server: Apache/2.2.14 (Unix) mod_ssl/2.2.14 OpenSSL/0.9.8l
>   Last-Modified: Wed, 21 Oct 2009 18:37:30 GMT
>   ETag: "dfe9e5c2-9044-4767645794207"
>   Accept-Ranges: bytes
>   Content-Length: 36932
>   Content-Type: application/x-rpm
>   Age: 223
>   Connection: close
Total file size 36932, 36932 to download, mtime Wed Oct 21 18:37:30 2009

.............................. 100.0% [36.1K (36.1K/s)]
Closing /tmp/test/FHS-2.3-29.x86_64.rpm (mtime 2009-10-21 15:37:30)




More information about the pld-bugs mailing list