From a17aa2f36041dcf2501c6a0b145207c82a382a0c Mon Sep 17 00:00:00 2001
From: Li Zhou
Date: Wed, 2 Sep 2020 16:19:31 +0800
Subject: bind: Security Advisory - bind - CVE-2020-8624
Backport patch from to solve CVE-2020-8624.
(From OE-Core rev: 660d170b6889b5e644da9fbef22220f63169aeb5)
Signed-off-by: Li Zhou
Signed-off-by: Anuj Mittal
Signed-off-by: Richard Purdie
---
.../bind/bind/CVE-2020-8624.patch | 33 ++++++++++++++++++++++
1 file changed, 33 insertions(+)
create mode 100644 meta/recipes-connectivity/bind/bind/CVE-2020-8624.patch
(limited to 'meta/recipes-connectivity/bind/bind/CVE-2020-8624.patch')
diff --git a/meta/recipes-connectivity/bind/bind/CVE-2020-8624.patch b/meta/recipes-connectivity/bind/bind/CVE-2020-8624.patch
new file mode 100644
index 0000000000..9cffe358bf
--- /dev/null
+++ b/meta/recipes-connectivity/bind/bind/CVE-2020-8624.patch
@@ -0,0 +1,33 @@
+From a73c3d30de7fe98af9e4dc0e490f732a48412380 Mon Sep 17 00:00:00 2001
+From: Mark Andrews
+Date: Wed, 29 Jul 2020 23:36:03 +1000
+Subject: [PATCH] bind: Update-policy 'subdomain' was incorrectly treated as
+ 'zonesub'
+
+resulting in names outside the specified subdomain having the wrong
+restrictions for the given key.
+
+Upstream-Status: Backport
+CVE: CVE-2020-8624
+Signed-off-by: Li Zhou
+---
+ bin/named/zoneconf.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/bin/named/zoneconf.c b/bin/named/zoneconf.c
+index e237bdb..4898447 100644
+--- a/bin/named/zoneconf.c
++++ b/bin/named/zoneconf.c
+@@ -237,7 +237,8 @@ configure_zone_ssutable(const cfg_obj_t *zconfig, dns_zone_t *zone,
+
+ str = cfg_obj_asstring(matchtype);
+ CHECK(dns_ssu_mtypefromstring(str, &mtype));
+- if (mtype == dns_ssumatchtype_subdomain) {
++ if (mtype == dns_ssumatchtype_subdomain &&
++ strcasecmp(str, "zonesub") == 0) {
+ usezone = true;
+ }
+
+--
+1.9.1
+
--
cgit v1.2.3-54-g00ecf