If I start gpg-agent, and then sign something, I need to specify the
passphrase (as expected). I can then sign new documents without having
to enter a passphrase again.
If I then try to decrypt something, I need to specify the passphrase
again. In the pinentry I see that I am asked for a different ID. The
main key ID is also included in the dialogue box.
Why does not gpgv use the main key ID when it talks to gpg-agent? Then
I would not have to enter the same passphrase twice.
(This becomes more of a problem when using gpg-preset-passphrase to
pre-load the passphrase. The cache-id of the main key ID is just what
the gpg2 --fingerprint prints out, with the colons removed, but the
cache-id of the subkey used for decryption is not as easy to figure
out. The only way I found was to enable debug in the gpg-agent, and
see it in the logs there.)
I have seen this using gpg 1.4.11, and the problem is still present
on the master branch of the Git repo.
(Note: I wish to work more with the bugtracker. I have a fix for issue
1561, 1526, 1467 (all dups) that I'd like to attach to one of them, so
please grant me the User role.)