[git] GnuPG - branch, master, updated. post-nuke-of-trailing-ws-45-g70b871a

by Marcus Brinkmann cvs at cvs.gnupg.org
Wed Apr 20 12:02:32 CEST 2011


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  70b871abbc4ec0968152968c10269cee72286df3 (commit)
      from  b5f585f7d796313cf7ae3d3fd35ed462a1f3d574 (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 70b871abbc4ec0968152968c10269cee72286df3
Author: Marcus Brinkmann <marcus.brinkmann at ruhr-uni-bochum.de>
Date:   Wed Apr 20 11:33:09 2011 +0200

    Fix gpg-agent secure memory leak in OpenPGP private key import.
    
    2011-04-20  Marcus Brinkmann  <mb at g10code.com>
    
            * command.c (cmd_import_key): Release key from failed import
            before converting openpgp private key in the openpgp-private-key
            case.

diff --git a/agent/ChangeLog b/agent/ChangeLog
index e8570f7..e342b57 100644
--- a/agent/ChangeLog
+++ b/agent/ChangeLog
@@ -1,3 +1,9 @@
+2011-04-20  Marcus Brinkmann  <mb at g10code.com>
+
+	* command.c (cmd_import_key): Release key from failed import
+        before converting openpgp private key in the openpgp-private-key
+        case.
+
 2011-04-17  Ben Kibbey <bjk at luxsci.net>
 
 	* command.c (cmd_passwd): Check for an error before presetting.
diff --git a/agent/command.c b/agent/command.c
index 9f45afb..34617ad 100644
--- a/agent/command.c
+++ b/agent/command.c
@@ -1827,6 +1827,8 @@ cmd_import_key (assuan_context_t ctx, char *line)
          used to protect the key using the same code as for regular
          key import. */
 
+      xfree (key);
+      key = NULL;
       err = convert_from_openpgp (ctrl, openpgp_sexp, grip,
                                   ctrl->server_local->keydesc, cache_nonce,
                                   &key, &passphrase);

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

Summary of changes:
 agent/ChangeLog |    6 ++++++
 agent/command.c |    2 ++
 2 files changed, 8 insertions(+), 0 deletions(-)


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




More information about the Gnupg-commits mailing list