[git] GnuPG - branch, master, updated. gnupg-2.1.6-26-g23d8609

by Werner Koch cvs at cvs.gnupg.org
Wed Jul 29 16:15:55 CEST 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".

The branch, master has been updated
       via  23d8609f4b5ec3432323a676fd7ef225c0ef71a1 (commit)
       via  9502d7f50a0897ba23cf15ab13ac498ac6ba4d5b (commit)
      from  8b2b988309cbc5af339beb0a55ff71d7464eb646 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit 23d8609f4b5ec3432323a676fd7ef225c0ef71a1
Author: Werner Koch <wk at gnupg.org>
Date:   Wed Jul 29 16:10:54 2015 +0200

    gpg: Do not return "Legacy Key" from lookup if a key is expired.
    
    * g10/getkey.c (lookup): Map GPG_ERR_LEGACY_KEY.
    --
    
    If an expired key is directly followed by a legacy key in the keyring,
    the lookup function incorrectly returned "legacy key" instead of
    "unusable key".  We fix it by handling not found identical to a legacy
    key if the last finish lookup failed.
    
    Signed-off-by: Werner Koch <wk at gnupg.org>

diff --git a/g10/getkey.c b/g10/getkey.c
index 5f118ea..14b912a 100644
--- a/g10/getkey.c
+++ b/g10/getkey.c
@@ -2633,7 +2633,8 @@ found:
       *ret_keyblock = ctx->keyblock; /* Return the keyblock.  */
       ctx->keyblock = NULL;
     }
-  else if (gpg_err_code (rc) == GPG_ERR_NOT_FOUND && no_suitable_key)
+  else if ((gpg_err_code (rc) == GPG_ERR_NOT_FOUND
+            || gpg_err_code (rc) == GPG_ERR_LEGACY_KEY) && no_suitable_key)
     rc = want_secret? GPG_ERR_UNUSABLE_SECKEY : GPG_ERR_UNUSABLE_PUBKEY;
   else if (gpg_err_code (rc) == GPG_ERR_NOT_FOUND)
     rc = want_secret? GPG_ERR_NO_SECKEY : GPG_ERR_NO_PUBKEY;

commit 9502d7f50a0897ba23cf15ab13ac498ac6ba4d5b
Author: Werner Koch <wk at gnupg.org>
Date:   Wed Jul 29 15:46:40 2015 +0200

    doc: Document that gpg --edit-key's toggle is a nop.
    
    --

diff --git a/doc/gpg.texi b/doc/gpg.texi
index 73a80a8..86726b3 100644
--- a/doc/gpg.texi
+++ b/doc/gpg.texi
@@ -818,7 +818,7 @@ create a signature of any type desired.
 
   @item toggle
   @opindex keyedit:toggle
-  Toggle between public and secret key listing.
+  This is dummy command which exists only for backward compatibility.
 
   @item clean
   @opindex keyedit:clean

-----------------------------------------------------------------------

Summary of changes:
 doc/gpg.texi | 2 +-
 g10/getkey.c | 3 ++-
 2 files changed, 3 insertions(+), 2 deletions(-)


hooks/post-receive
-- 
The GNU Privacy Guard
http://git.gnupg.org




More information about the Gnupg-commits mailing list