Can't enter passphrase in su session.

Chris Babcock cbabcock at
Wed May 20 23:36:48 CEST 2009

On Wed, 20 May 2009 20:00:42 +0100
mike _ <arizonagroovejet at> wrote:

> Can anyone offer any insight in this issue?

In .bash_profile, you will have something *like* this:
if test -f $HOME/.gpg-agent-info &&    kill -0 `cut -d: -f 2 $HOME/.gpg-agent-info`\
2>/dev/null; then
     GPG_AGENT_INFO=`cat $HOME/.gpg-agent-info`
     export GPG_AGENT_INFO
     eval `/usr/bin/gpg-agent --daemon`
     echo $GPG_AGENT_INFO >$HOME/.gpg-agent-info

You *may* have something like this:

if [ -f /etc/bashrc ]; then
        . /etc/bashrc

The code to launch gpg-agent needs to be in .bashrc if you want it to
execute for su users. If your .bash_profile executes your .bashrc as
above then you can remove the definition from .bash_profile.

Chris Babcock

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 489 bytes
Desc: not available
URL: </pipermail/attachments/20090520/bed80c62/attachment.pgp>

More information about the Gnupg-users mailing list