Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 264656 - app-crypt/pinentry with "caps" in USE does not read passphrases
Summary: app-crypt/pinentry with "caps" in USE does not read passphrases
Status: RESOLVED TEST-REQUEST
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Sven Wegener
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-04-02 17:11 UTC by Patrick Beckmann
Modified: 2015-08-23 20:52 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Patrick Beckmann 2009-04-02 17:11:34 UTC
Gnupg in combination with a pinentry installation, that was compiled with "caps" in USE, does not read passphrases, when called as "root" and no "DISPLAY" environment variable is set. It states, that the entry was cancelled. I think, that in this case pinentry-curses is called.

This bug makes Gnupg unusable. Setting "-caps" for pinentry makes the passphrase entry working again.

Used versions: app-crypt/gnupg-2.0.10, app-crypt/pinentry-0.7.5

Reproducible: Always

Steps to Reproduce:
1. Set "caps" in the USE variable
2. emerge gnupg pinentry
3. unset DISPLAY
4. gpg --edit-key <id of your key pair>
5. > passwd
Actual Results:  
The output is something like this:

"gpg-agent[11959]: command get_passphrase failed: Operation cancelled
gpg: cancelled by user
Can't edit this key: General error"

Expected Results:  
A prompt should show up, where I can enter the old passphrase (and then the new one two times).
Comment 1 Sven Wegener gentoo-dev 2009-04-02 18:23:12 UTC
What are the USE flags you've built pinentry with?
Comment 2 Patrick Beckmann 2009-04-03 08:43:18 UTC
On one machine with "caps ncurses -gtk -qt3", on another for reproducing with "caps gtk ncurses -qt3". The output of "emerge --info" of the first machine follows:

# emerge --info 
Portage 2.1.6.7 (hardened/linux/x86/2008.0/server, gcc-3.4.6, glibc-2.8_p20080602-r1, 2.6.28-hardened-r7 i686)
=================================================================
System uname: Linux-2.6.28-hardened-r7-i686-AMD_Athlon-tm-_Processor-with-glibc2.3.2
Timestamp of tree: Fri, 03 Apr 2009 00:45:01 +0000
app-shells/bash:     3.2_p39
dev-java/java-config: 1.3.7-r1, 2.1.7
dev-lang/python:     2.5.2-r7
sys-apps/baselayout: 1.12.11.1
sys-apps/sandbox:    1.2.18.1-r2
sys-devel/autoconf:  2.13, 2.63
sys-devel/automake:  1.7.9-r1, 1.9.6-r2, 1.10.2
sys-devel/binutils:  2.18-r3
sys-devel/gcc-config: 1.4.0-r4
sys-devel/libtool:   1.5.26
virtual/os-headers:  2.6.28-r1
ACCEPT_KEYWORDS="x86"
CBUILD="i686-pc-linux-gnu"
CFLAGS="-mtune=athlon -O2 -pipe"
CHOST="i686-pc-linux-gnu"
CONFIG_PROTECT="/etc /var/bind"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/env.d/java/ /etc/fonts/fonts.conf /etc/gconf /etc/php/apache2-php5/ext-active/ /etc/php/cgi-php5/ext-active/ /etc/php/cli-php5/ext-active/ /etc/revdep-rebuild /etc/terminfo /etc/udev/rules.d"
CXXFLAGS="-mtune=athlon -O2 -pipe"
DISTDIR="/usr/portage/distfiles"
EMERGE_DEFAULT_OPTS="--nospinner"
FEATURES="collision-protect distlocks fixpackages parallel-fetch protect-owned sandbox sfperms strict unmerge-orphans userfetch userpriv usersandbox"
GENTOO_MIRRORS="http://10.6.11.115/mirrors/gentoo/ ftp://linux.rz.ruhr-uni-bochum.de/gentoo-mirror/ http://ftp.uni-erlangen.de/pub/mirrors/gentoo ftp://ftp.uni-erlangen.de/pub/mirrors/gentoo http://mirrors.sec.informatik.tu-darmstadt.de/gentoo http://ftp.easynet.nl/mirror/gentoo/ ftp://sunsite.informatik.rwth-aachen.de/pub/Linux/gentoo"
LANG="de_DE@euro"
LC_ALL="de_DE@euro"
LDFLAGS="-Wl,-O1"
LINGUAS="de"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.europe.gentoo.org/gentoo-portage"
USE="3dnow 3dnowext apache2 berkdb bzip2 caps cli cracklib crypt dri gd gdbm hardened iconv imagemagick imap innodb isdnlog java6 jpeg kpathsea latin1 libwww logrotate maildir midi mmx mudflap mysql ncurses nls nptl nptlonly pam pcre perl pic png postfix pppd python quotas readline reflection samba sasl session slang snmp spell spl ssl symlink sysfs tcpd threads truetype unicode urandom x86 xml xorg zlib" APACHE2_MODULES="actions alias auth_basic auth_digest authn_anon authn_dbd authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache dav dav_fs dav_lock dbd deflate dir disk_cache env expires ext_filter file_cache filter headers ident imagemap include info log_config logio mem_cache mime mime_magic negotiation proxy proxy_ajp proxy_balancer proxy_connect proxy_http rewrite setenvif so speling status unique_id userdir usertrack vhost_alias" ELIBC="glibc" INPUT_DEVICES="keyboard" KERNEL="linux" LINGUAS="de" USERLAND="GNU"
Unset:  CPPFLAGS, CTARGET, FFLAGS, INSTALL_MASK, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY
Comment 3 Samuli Suominen (RETIRED) gentoo-dev 2010-06-06 05:12:07 UTC
Can we get a update for 0.8.0 ? Please get back to us and reopen the bug then.
Comment 4 Bertrand Jacquin 2015-08-23 20:52:09 UTC
(In reply to Samuli Suominen from comment #3)
> Can we get a update for 0.8.0 ? Please get back to us and reopen the bug
> then.

This is still the case as of today with app-crypt/pinentry-0.9.0

A workaround is to give read permission to group on $(tty)