Bug#814733: /usr/bin/dget: dget does not unquote in file: URLs
Lars Wirzenius
liw at liw.fi
Sun Feb 14 19:27:20 UTC 2016
Package: devscripts
Version: 2.15.3
Severity: normal
File: /usr/bin/dget
Dear Maintainer,
dget does not seem to un-quote URL encodings in file: URLs. For
example, %2B in a URL is a way to express the + character, but dget
interprets that as the character sequence %, 2, and B. curl gets this
right (wget doesn't handle file: URLs at all).
Example: I have a file with a + in the filename, and if I create a
file: URL and encode the + as %2B, and run curl, it works:
$ curl -s file:///home/liw/code/ick/liw.state/obbench/builds/30/artifacts/obbench_0.11%2Bgit.0ci30-1.unstable_source.changes | wc -l
29
Getting the same file with dget doesn't work:
$ dget -d file:///home/liw/code/ick/liw.state/obbench/builds/30/artifacts/obbench_0.11%2Bgit.0ci30-1.unstable_source.changes | wc -l
cp: cannot stat ‘/home/liw/code/ick/liw.state/obbench/builds/30/artifacts/obbench_0.11%2Bgit.0ci30-1.unstable_source.changes’: No such file or directory
dget: curl obbench_0.11%2Bgit.0ci30-1.unstable_source.changes file:///home/liw/code/ick/liw.state/obbench/builds/30/artifacts/obbench_0.11%2Bgit.0ci30-1.unstable_source.changes failed
This seems to be because dget handles file: URLs itself, by
hardlinking or copying the file, rather than using curl.
I ran into this because I have a build automation that uses dget to
fetch built packages and puts them in an APT repository, and uses
file: URLs. I have worked around this dget behaviour by un-escaping
the URL myself.
-- Package-specific info:
--- /etc/devscripts.conf ---
--- ~/.devscripts ---
DEBSIGN_KEYID=B8611E9C
DSCVERIFY_KEYRINGS=/home/liw/.gnupg/pubring.gpg
-- System Information:
Debian Release: 8.3
APT prefers stable-updates
APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages devscripts depends on:
ii dpkg-dev 1.17.26
ii libc6 2.19-18+deb8u2
ii perl 5.20.2-3+deb8u3
ii python3 3.4.2-2
pn python3:any <none>
Versions of packages devscripts recommends:
ii at 3.1.16-1
ii curl 7.38.0-4+deb8u3
ii dctrl-tools 2.23
ii debian-keyring 2015.04.10
ii dput 0.9.6.4
ii equivs 2.0.9
ii fakeroot 1.20.2-1
ii file 1:5.22+15-2+deb8u1
ii gnupg 1.4.18-7
ii libdistro-info-perl 0.14
ii libencode-locale-perl 1.03-1
ii libjson-perl 2.61-1
ii liblwp-protocol-https-perl 6.06-2
ii libparse-debcontrol-perl 2.005-4
ii libsoap-lite-perl 1.11-1
ii liburi-perl 1.64-1
ii libwww-perl 6.08-1
ii lintian 2.5.30+deb8u4
ii man-db 2.7.0.2-5
ii patch 2.7.5-1
ii patchutils 0.3.3-1
ii python3-debian 0.1.27
ii python3-magic 1:5.22+15-2+deb8u1
ii sensible-utils 0.0.9
ii strace 4.9-2
ii unzip 6.0-16+deb8u2
ii wdiff 1.2.2-1
ii wget 1.16-1
ii xz-utils 5.1.1alpha+20120614-2+b3
Versions of packages devscripts suggests:
ii bsd-mailx [mailx] 8.1.2-0.20141216cvs-2
ii build-essential 11.7
pn cvs-buildpackage <none>
pn debbindiff <none>
pn devscripts-el <none>
pn gnuplot <none>
ii gpgv 1.4.18-7
ii libauthen-sasl-perl 2.1600-1
ii libfile-desktopentry-perl 0.07-1
ii libnet-smtp-ssl-perl 1.01-3
pn libterm-size-perl <none>
ii libtimedate-perl 2.3000-2
pn libyaml-syck-perl <none>
ii mailutils [mailx] 1:2.99.98-2
ii mutt 1.5.23-3
ii openssh-client [ssh-client] 1:6.7p1-5+deb8u1
pn svn-buildpackage <none>
ii w3m 0.5.3-19
-- no debconf information
More information about the devscripts-devel
mailing list