unbound: add patch to fix dns64 crash 7730/head
authorJan Pavlinec <jan.pavlinec@nic.cz>
Wed, 19 Dec 2018 09:01:30 +0000 (10:01 +0100)
committerJan Pavlinec <jan.pavlinec@nic.cz>
Wed, 19 Dec 2018 09:19:06 +0000 (10:19 +0100)
Signed-off-by: Jan Pavlinec <jan.pavlinec@nic.cz>
net/unbound/Makefile
net/unbound/patches/101-dns64-crash.patch [new file with mode: 0644]

index 3de8a8eecdb17ed554ffd3215e4315fe0e1452b3..ad629cf1a8235ba9a2f05ea6f55463f588dd81a6 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=unbound
 PKG_VERSION:=1.8.3
-PKG_RELEASE:=1
+PKG_RELEASE:=2
 
 PKG_LICENSE:=BSD-3-Clause
 PKG_LICENSE_FILES:=LICENSE
diff --git a/net/unbound/patches/101-dns64-crash.patch b/net/unbound/patches/101-dns64-crash.patch
new file mode 100644 (file)
index 0000000..e27f072
--- /dev/null
@@ -0,0 +1,23 @@
+From 023411f97505c8c7e375112ad853b6a40ef848a6 Mon Sep 17 00:00:00 2001
+From: Wouter Wijngaards <wouter@nlnetlabs.nl>
+Date: Wed, 12 Dec 2018 16:03:05 +0000
+Subject: [PATCH] - Fix for crash in dns64 module if response is null.
+
+git-svn-id: file:///svn/unbound/trunk@5025 be551aaa-1e26-0410-a405-d3ace91eadb9
+---
+ dns64/dns64.c | 1 +
+ doc/Changelog | 3 +++
+ 2 files changed, 4 insertions(+)
+
+diff --git a/dns64/dns64.c b/dns64/dns64.c
+index 77e68900..f2834da2 100644
+--- a/dns64/dns64.c
++++ b/dns64/dns64.c
+@@ -628,6 +628,7 @@ handle_event_moddone(struct module_qstate* qstate, int id)
+       /* Store the response in cache. */
+       if ( (!iq || !iq->started_no_cache_store) &&
++              qstate->return_msg && qstate->return_msg->rep &&
+               !dns_cache_store(qstate->env, &qstate->qinfo, qstate->return_msg->rep,
+               0, 0, 0, NULL, qstate->query_flags))
+               log_err("out of memory");