[Pkg-gnupg-maint] Bug#778480: gpg-connect-agent: percent+ function doesn't encode '+'
Michael Gold
michael at bitplane.org
Sun Feb 15 16:27:36 UTC 2015
Package: gnupg-agent
Version: 2.0.26-4
The 'percent+' function URL-encodes its argument and replaces spaces
with plus signs. But it doesn't encode plus signs in its argument;
e.g.,
gpg-connect-agent --subst '/echo ${percent+ foo+ bar}' /bye
prints
foo++bar
which would decode to "foo bar" instead of "foo+ bar".
Plus signs should be encoded as %2b to make the encoding reversible.
The above command should print "foo%2b+bar".
When calling jnlib/stringhelp.c:percent_escape from gpg-connect-agent.c,
'+' could be added to the 'extra' argument to do this. But I think it
would be preferable for percent_escape to always encode '+', like ':'
and '%' (unpercent_string will decode arbitrary hex values). Actually,
there's a function percent_plus_escape in common/percent.c that appears
to do it properly.
- Michael
-- System Information:
Debian Release: 8.0
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: arm64
Kernel: Linux 3.16.0-4-amd64 (SMP w/8 CPU cores)
Locale: LANG=en_CA.UTF-8, LC_CTYPE=en_CA.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: sysvinit (via /sbin/init)
Versions of packages gnupg-agent depends on:
ii libassuan0 2.1.2-2
ii libc6 2.19-15
ii libgcrypt20 1.6.2-4+b1
ii libgpg-error0 1.17-3
ii libpth20 2.0.7-20
ii libreadline6 6.3-8+b3
ii pinentry-curses [pinentry] 0.8.3-2
ii pinentry-gtk2 [pinentry] 0.8.3-2
ii pinentry-qt4 [pinentry] 0.8.3-2
Versions of packages gnupg-agent recommends:
ii gnupg 1.4.18-6
ii gnupg2 2.0.26-4
gnupg-agent suggests no packages.
-- no debconf information
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.alioth.debian.org/pipermail/pkg-gnupg-maint/attachments/20150215/6029c8f3/attachment.sig>
More information about the Pkg-gnupg-maint
mailing list