gnunet-svn
[Top][All Lists]
Advanced

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

[GNUnet-SVN] [gnunet] branch master updated: stop DNS lookup immediately


From: gnunet
Subject: [GNUnet-SVN] [gnunet] branch master updated: stop DNS lookup immediately instead of async to avoid use-after free if we get BOTH an IPv4 and IPv6 response
Date: Wed, 23 May 2018 23:37:07 +0200

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

grothoff pushed a commit to branch master
in repository gnunet.

The following commit(s) were added to refs/heads/master by this push:
     new 25f35d003 stop DNS lookup immediately instead of async to avoid 
use-after free if we get BOTH an IPv4 and IPv6 response
25f35d003 is described below

commit 25f35d003e2456be74bed0edf35743107c48ce32
Author: Christian Grothoff <address@hidden>
AuthorDate: Wed May 23 23:37:00 2018 +0200

    stop DNS lookup immediately instead of async to avoid use-after free if we 
get BOTH an IPv4 and IPv6 response
---
 src/gns/gnunet-service-gns_resolver.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/gns/gnunet-service-gns_resolver.c 
b/src/gns/gnunet-service-gns_resolver.c
index d3c07e997..8b20f2ae3 100644
--- a/src/gns/gnunet-service-gns_resolver.c
+++ b/src/gns/gnunet-service-gns_resolver.c
@@ -971,6 +971,8 @@ dns_result_parser (void *cls,
                                               &handle_dns_result,
                                               rh);
     GNUNET_DNSPARSER_free_packet (p);
+    GNUNET_DNSSTUB_resolve_cancel (rh->dns_request);
+    rh->dns_request = NULL;
     return;
   }
 
@@ -1110,6 +1112,8 @@ dns_result_parser (void *cls,
     rh->proc (rh->proc_cls,
               rd_count - skip,
               rd);
+    GNUNET_DNSSTUB_resolve_cancel (rh->dns_request);
+    rh->dns_request = NULL;
   }
   GNUNET_DNSPARSER_free_packet (p);
   if (NULL != rh->task_id)

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



reply via email to

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