[git] GnuPG - branch, master, updated. gnupg-2.1.3-32-g436f206

by Werner Koch cvs at cvs.gnupg.org
Thu May 7 15:43:05 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  436f2060721e997479a9dd5be8dfc73627dd49c9 (commit)
      from  d0d4984cfec54dee727b9e9d33d09e33c6f2e182 (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 436f2060721e997479a9dd5be8dfc73627dd49c9
Author: Werner Koch <wk at gnupg.org>
Date:   Thu May 7 15:42:00 2015 +0200

    agent: Minor change for 56b5c9f.
    
    * agent/call-pinentry.c (agent_askpin): Move option setting to ...
    (start_pinentry): here.  Fix error code check.
    
    Signed-off-by: Werner Koch <wk at gnupg.org>

diff --git a/agent/call-pinentry.c b/agent/call-pinentry.c
index 77b1739..0a0f95b 100644
--- a/agent/call-pinentry.c
+++ b/agent/call-pinentry.c
@@ -407,6 +407,20 @@ start_pinentry (ctrl_t ctrl)
 	return unlock_pinentry (rc);
     }
 
+
+  /* Indicate to the pinentry that it may read from an external cache.
+
+     It is essential that the pinentry respect this.  If the cached
+     password is not up to date and retry == 1, then, using a version
+     of GPG Agent that doesn't support this, won't issue another pin
+     request and the user won't get a chance to correct the
+     password.  */
+  rc = assuan_transact (entry_ctx, "OPTION allow-external-password-cache",
+			NULL, NULL, NULL, NULL, NULL, NULL);
+  if (rc && gpg_err_code (rc) != GPG_ERR_UNKNOWN_OPTION)
+    return unlock_pinentry (rc);
+
+
   {
     /* Provide a few default strings for use by the pinentries.  This
        may help a pinentry to avoid implementing localization code.  */
@@ -814,18 +828,6 @@ agent_askpin (ctrl_t ctrl,
   if (rc)
     return rc;
 
-  /* Indicate to the pinentry that it may read from an external cache.
-
-     It is essential that the pinentry respect this.  If the cached
-     password is not up to date and retry == 1, then, using a version
-     of GPG Agent that doesn't support this, won't issue another pin
-     request and the user won't get a chance to correct the
-     password.  */
-  rc = assuan_transact (entry_ctx, "OPTION allow-external-password-cache",
-			NULL, NULL, NULL, NULL, NULL, NULL);
-  if (rc && gpg_err_code (rc) != GPG_ERR_ASS_UNKNOWN_CMD)
-    return unlock_pinentry (rc);
-
   /* If we have a KEYINFO string and are normal, user, or ssh cache
      mode, we tell that the Pinentry so it may use it for own caching
      purposes.  Most pinentries won't have this implemented and thus

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

Summary of changes:
 agent/call-pinentry.c | 26 ++++++++++++++------------
 1 file changed, 14 insertions(+), 12 deletions(-)


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




More information about the Gnupg-commits mailing list