GNU bug report logs - #22941
25.1.50; epa-list-secret-keys does not find gpg private keys

Previous Next

Package: emacs;

Reported by: Iñigo Serna <inigoserna <at> gmail.com>

Date: Tue, 8 Mar 2016 11:00:02 UTC

Severity: normal

Tags: notabug

Found in version 25.1.50

Done: Daiki Ueno <ueno <at> gnu.org>

Bug is archived. No further changes may be made.

Full log


Message #12 received at control <at> debbugs.gnu.org (full text, mbox):

From: Daiki Ueno <ueno <at> gnu.org>
To: Iñigo Serna <inigoserna <at> gmail.com>
Cc: 22941 <at> debbugs.gnu.org
Subject: Re: bug#22941: 25.1.50;
 epa-list-secret-keys does not find gpg private keys
Date: Thu, 10 Mar 2016 12:30:50 +0900
tag 22941 notabug
close 22941
stop

Iñigo Serna <inigoserna <at> gmail.com> writes:

> Since a couple of months ago emacs 25.0.x (last tested as 2016/03/08
> from git master) can't open encrypted files (using symmetric keys), as
> epa can't find secret keys from gpg.
>
> This is the error message I get:
> """
> Error while decrypting with "gpg":
>
> gpg: encrypted with 2048-bit RSA key, ID C0ED9C8489B28C43, created 2016-01-12
>       "Iñigo Serna (XXX.YY) <inigo <at> XXX.YY>"
> gpg: decryption failed: No secret key
> """
>
> I use gpg (not gpg2) so I added '(setq epg-gpg-program "gpg")' to my
> configuration as new epa defaults to gpg2 when I've run "emacs -Q -nw".
>
> `epa-list-secret-keys` does not find any keys.
>
> This same configuration works ok with 24.5.1 (from Fedora 23 x86_64), and
> even `epa-list-secret-keys` shows the private keys correctly.

This behavior is intended, if the key was created with gpg2.  GnuPG 2.1
removed support for secring.gpg, which was used by pre-2.1 versions.
That is one of the reasons we switched the default to "gpg2".

See doc/whats-new-in-2.1.txt in GnuPG:

1.1 Removal of the secret keyring
─────────────────────────────────
[...]
  2.1.  However, any change to the private keys using the new /gpg/ will
  not show up when using pre-2.1 versions of GnuPG and vice versa.

Regards,
-- 
Daiki Ueno




This bug report was last modified 9 years and 69 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.