[git] GnuPG - branch, master, updated. gnupg-2.2.7-220-g79f165d

by Werner Koch cvs at cvs.gnupg.org
Mon Oct 8 15:48:10 CEST 2018


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  79f165d7a8bcc26972712bb0f0cc554d5c3d4e42 (commit)
      from  3c2ffd27f36dfe77005aa01005145904761d8743 (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 79f165d7a8bcc26972712bb0f0cc554d5c3d4e42
Author: Werner Koch <wk at gnupg.org>
Date:   Mon Oct 8 15:38:37 2018 +0200

    gpg: Make --skip-hidden-recipients work again.
    
    * g10/pubkey-enc.c (get_session_key): Take care of
    opt.skip_hidden_recipients.
    --
    This was lost due to
    Fixes-commit: ce2f71760155b71a71418fe145a557c99bd52290
    GnuPG-bug-id: 4169
    
    Signed-off-by: Werner Koch <wk at gnupg.org>

diff --git a/g10/pubkey-enc.c b/g10/pubkey-enc.c
index 32b1ed0..ad0a77e 100644
--- a/g10/pubkey-enc.c
+++ b/g10/pubkey-enc.c
@@ -110,6 +110,16 @@ get_session_key (ctrl_t ctrl, struct pubkey_enc_list *list, DEK *dek)
           continue;
         }
 
+      /* FIXME: The list needs to be sorted so that we try the keys in
+       * an appropriate order.  For example:
+       * - On-disk keys w/o protection
+       * - On-disk keys with a cached passphrase
+       * - On-card keys of an active card
+       * - On-disk keys with protection
+       * - On-card keys from cards which are not plugged it.  Here a
+       *   cancel-all button should stop aksing for other cards.
+       * Without any anonymous keys the sorting can be skipped.
+       */
       for (k = list; k; k = k->next)
         {
           if (!(k->pubkey_algo == PUBKEY_ALGO_ELGAMAL_E
@@ -129,6 +139,9 @@ get_session_key (ctrl_t ctrl, struct pubkey_enc_list *list, DEK *dek)
 
           if (!k->keyid[0] && !k->keyid[1])
             {
+              if (opt.skip_hidden_recipients)
+                continue;
+
               if (!opt.quiet)
                 log_info (_("anonymous recipient; trying secret key %s ...\n"),
                           keystr (keyid));

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

Summary of changes:
 g10/pubkey-enc.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)


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




More information about the Gnupg-commits mailing list