gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gnunet] branch master updated: fix NULL ptr deref in attestations


From: gnunet
Subject: [gnunet] branch master updated: fix NULL ptr deref in attestations
Date: Tue, 03 Mar 2020 13:36:36 +0100

This is an automated email from the git hooks/post-receive script.

martin-schanzenbach pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new c0236414b fix NULL ptr deref in attestations
c0236414b is described below

commit c0236414b243d7bf8a60e9906f44fe527df49631
Author: Schanzenbach, Martin <address@hidden>
AuthorDate: Tue Mar 3 13:32:31 2020 +0100

    fix NULL ptr deref in attestations
---
 src/reclaim/reclaim_attestation.c | 7 +++++++
 1 file changed, 7 insertions(+)

diff --git a/src/reclaim/reclaim_attestation.c 
b/src/reclaim/reclaim_attestation.c
index 66da8e74a..bdf80a709 100644
--- a/src/reclaim/reclaim_attestation.c
+++ b/src/reclaim/reclaim_attestation.c
@@ -336,6 +336,13 @@ GNUNET_RECLAIM_attestation_list_deserialize (const char 
*data, size_t data_size)
     ale->attestation =
       GNUNET_RECLAIM_attestation_deserialize (read_ptr,
                                               data_size - (read_ptr - data));
+    if (NULL == ale->attestation)
+    {
+      GNUNET_log (GNUNET_ERROR_TYPE_WARNING,
+                  "Failed to deserialize malformed attestation.\n");
+      GNUNET_free (ale);
+      return al;
+    }
     GNUNET_CONTAINER_DLL_insert (al->list_head, al->list_tail, ale);
     att_len = GNUNET_RECLAIM_attestation_serialize_get_size (ale->attestation);
     read_ptr += att_len;

-- 
To stop receiving notification emails like this one, please contact
address@hidden.



reply via email to

[Prev in Thread] Current Thread [Next in Thread]