[git] GPGME - branch, master, updated. gpgme-1.11.1-94-g1686e07

by Andre Heinecke cvs at cvs.gnupg.org
Mon Jul 16 19:48:34 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 "GnuPG Made Easy".

The branch, master has been updated
       via  1686e07e77a1eee3b2708d0231a5a549956021f7 (commit)
       via  cc21101a7494ea0a17c3012fcb86e77b00b494fa (commit)
      from  1933f5b8056b2671301379106cca4504c4187795 (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 1686e07e77a1eee3b2708d0231a5a549956021f7
Author: Andre Heinecke <aheinecke at intevation.de>
Date:   Mon Jul 16 19:47:11 2018 +0200

    json: Fix crash on invalid json
    
    * src/gpgme-json.c (process_request): Init res. Check for
    json object before encode and chunk.
    
    --
    If json is invalid we can't read chunksize and would crash
    in encode and chunk.

diff --git a/src/gpgme-json.c b/src/gpgme-json.c
index 0aeb7f9..06f09ef 100644
--- a/src/gpgme-json.c
+++ b/src/gpgme-json.c
@@ -3104,7 +3104,7 @@ process_request (const char *request)
   int helpmode;
   int is_getmore = 0;
   const char *op;
-  char *res;
+  char *res = NULL;
   int idx;
 
   response = xjson_CreateObject ();
@@ -3188,7 +3188,7 @@ process_request (const char *request)
       else
         res = cJSON_PrintUnformatted (response);
     }
-  else
+  else if (json)
     res = encode_and_chunk (json, response);
   if (!res)
     log_error ("Printing JSON data failed\n");

commit cc21101a7494ea0a17c3012fcb86e77b00b494fa
Author: Andre Heinecke <aheinecke at intevation.de>
Date:   Mon Jul 16 19:46:04 2018 +0200

    json: Fix uninitialized key unref in op_delete
    
    * src/gpgme-json.c (op_delete): Init key.

diff --git a/src/gpgme-json.c b/src/gpgme-json.c
index ecdcc08..0aeb7f9 100644
--- a/src/gpgme-json.c
+++ b/src/gpgme-json.c
@@ -2607,7 +2607,7 @@ op_delete (cjson_t request, cjson_t result)
   gpgme_ctx_t ctx = NULL;
   gpgme_ctx_t keylist_ctx = NULL;
   gpgme_protocol_t protocol;
-  gpgme_key_t key;
+  gpgme_key_t key = NULL;
   int secret = 0;
   cjson_t j_key = NULL;
 

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

Summary of changes:
 src/gpgme-json.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)


hooks/post-receive
-- 
GnuPG Made Easy
http://git.gnupg.org




More information about the Gnupg-commits mailing list