dnsmasq: latest pre-2.81 patches
authorKevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Fri, 18 Jan 2019 08:56:59 +0000 (08:56 +0000)
committerKevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
Thu, 31 Jan 2019 10:13:05 +0000 (10:13 +0000)
Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
33 files changed:
package/network/services/dnsmasq/Makefile
package/network/services/dnsmasq/patches/0001-Impove-cache-behaviour-for-TCP-connections.patch
package/network/services/dnsmasq/patches/0002-Ensure-that-AD-bit-is-reset-on-answers-from-address-.patch
package/network/services/dnsmasq/patches/0003-Remove-ability-to-compile-without-IPv6-support.patch
package/network/services/dnsmasq/patches/0004-Don-t-forward-.bind-.server-queries-upstream.patch
package/network/services/dnsmasq/patches/0005-Fix-logging-in-cf5984367bc6a949e3803a576512c5a7bc48e.patch
package/network/services/dnsmasq/patches/0006-Fix-spurious-AD-flags-in-some-DNS-replies-from-local.patch
package/network/services/dnsmasq/patches/0007-Do-not-rely-on-dead-code-elimination-use-array-inste.patch
package/network/services/dnsmasq/patches/0008-Fix-Makefile-lines-generating-UBUS-linker-config.patch
package/network/services/dnsmasq/patches/0009-Revert-68f6312d4bae30b78daafcd6f51dc441b8685b1e.patch
package/network/services/dnsmasq/patches/0010-Remove-the-NO_FORK-compile-time-option-and-support-f.patch
package/network/services/dnsmasq/patches/0011-Free-config-file-values-on-parsing-errors.patch
package/network/services/dnsmasq/patches/0013-Treat-DS-and-DNSKEY-queries-being-forwarded-the-same.patch
package/network/services/dnsmasq/patches/0014-Fix-option-parsing-errors-introduced-in-59e470381f84.patch
package/network/services/dnsmasq/patches/0015-fix-ipv6-ipset-bug-in-master.patch
package/network/services/dnsmasq/patches/0016-build-failure-on-master-with-NO_DHCPv6-and-fix.patch
package/network/services/dnsmasq/patches/0017-Alter-DHCP-address-selection-after-DECLINE-in-consec.patch
package/network/services/dnsmasq/patches/0018-Tidy-all_addr-union-merge-log-and-rcode-fields.patch
package/network/services/dnsmasq/patches/0019-Tidy-address-union-handling-move-class-into-explicit.patch
package/network/services/dnsmasq/patches/0020-Futher-address-union-tidying.patch
package/network/services/dnsmasq/patches/0021-Remove-nested-struct-union-in-cache-records-and-all_.patch
package/network/services/dnsmasq/patches/0022-File-logic-bug-in-cache-marshalling-code.-Introduced.patch
package/network/services/dnsmasq/patches/0023-Fix-typo-in-ra-param-man-page-section.patch
package/network/services/dnsmasq/patches/0024-Cache-SRV-records.patch
package/network/services/dnsmasq/patches/0025-Fix-crash-freeing-negative-SRV-cache-entries.patch
package/network/services/dnsmasq/patches/0026-Check-for-not-DS-or-DNSKEY-in-is_outdated_cname_poin.patch
package/network/services/dnsmasq/patches/0027-Fix-e7bfd556c079c8b5e7425aed44abc35925b24043-to-actu.patch
package/network/services/dnsmasq/patches/0028-Tidy-cache_blockdata_free.patch
package/network/services/dnsmasq/patches/0029-Fix-removal-of-DHCP_CLIENT_MAC-options-from-DHCPv6-r.patch
package/network/services/dnsmasq/patches/0030-Fix-entries-in-etc-hosts-disabling-static-leases.patch
package/network/services/dnsmasq/patches/0031-Fix-missing-braces-in-8eac67c0a15b673c8d27002c248651.patch [new file with mode: 0644]
package/network/services/dnsmasq/patches/0031-fix-previous-commit.patch [deleted file]
package/network/services/dnsmasq/patches/0032-Change-read_leases-to-skip-invalid-entries.patch [new file with mode: 0644]

index a3a0b12ab13b50c16d51ceeb1b39ad00dc339a7d..03114e7d925764e3bd13bfadb7eb3b470f2f9847 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=dnsmasq
 PKG_VERSION:=2.80
-PKG_RELEASE:=6
+PKG_RELEASE:=7
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.xz
 PKG_SOURCE_URL:=http://thekelleys.org.uk/dnsmasq
index 5c13bf937b058e44ba1575d6da274ac68627055f..c801f258b38a73c5457711521325a98959b1c838 100644 (file)
@@ -1,7 +1,7 @@
 From a799ca0c6314ad73a97bc6c89382d2712a9c0b0e Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Thu, 18 Oct 2018 19:35:29 +0100
-Subject: [PATCH 01/30] Impove cache behaviour for TCP connections.
+Subject: [PATCH 01/32] Impove cache behaviour for TCP connections.
 
 For ease of implementaion, dnsmasq has always forked a new process to
 handle each incoming TCP connection. A side-effect of this is that any
index b23766d7155d5c022a1dda46045a8b0d5398de26..0a115fe0bebc07be48796a2369b452492a9782f2 100644 (file)
@@ -1,7 +1,7 @@
 From a220545c4277cba534be5ef4638b5076fc7d2cf4 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Mon, 22 Oct 2018 18:21:48 +0100
-Subject: [PATCH 02/30] Ensure that AD bit is reset on answers from
+Subject: [PATCH 02/32] Ensure that AD bit is reset on answers from
  --address=/<domain>/<address>.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
index 352d071882dd9f9f23228be66d7df00f5f1c9ab8..527a38d249d16593036455f420c10fa2eccdcb63 100644 (file)
@@ -1,7 +1,7 @@
 From ee8750451b49d27b180517a4e35b636be0fae575 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Tue, 23 Oct 2018 22:10:17 +0100
-Subject: [PATCH 03/30] Remove ability to compile without IPv6 support.
+Subject: [PATCH 03/32] Remove ability to compile without IPv6 support.
 
 This was the source of a large number of #ifdefs, originally
 included for use with old embedded libc versions. I'm
index cf59309298bf12c6b5f064a11ef1dfbc0090a838..cbf211a64471c60981772c6162b5f3e7f14e58f0 100644 (file)
@@ -1,7 +1,7 @@
 From cf5984367bc6a949e3803a576512c5a7bc48ebab Mon Sep 17 00:00:00 2001
 From: Vladislav Grishenko <themiron@mail.ru>
 Date: Thu, 18 Oct 2018 04:55:21 +0500
-Subject: [PATCH 04/30] Don't forward *.bind/*.server queries upstream
+Subject: [PATCH 04/32] Don't forward *.bind/*.server queries upstream
 
 Chaos .bind and .server (RFC4892) zones are local, therefore
 don't forward queries upstream to avoid mixing with supported
index 0281a2c98c4774b2c99d8f2544ecfba8e69fac84..473297bcdc5c09d91331700e8545aeabdd95ff4c 100644 (file)
@@ -1,7 +1,7 @@
 From cbb5b17ad8e03e08ade62376a4f6a2066e55960d Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Tue, 23 Oct 2018 23:45:57 +0100
-Subject: [PATCH 05/30] Fix logging in cf5984367bc6a949e3803a576512c5a7bc48ebab
+Subject: [PATCH 05/32] Fix logging in cf5984367bc6a949e3803a576512c5a7bc48ebab
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
 ---
index 0433cca18ecdeec906700ca3d6f38e4c8e6e7cad..bebc7ba4534f4871fc5d3f24c04e36bd3149ae0b 100644 (file)
@@ -1,7 +1,7 @@
 From 6f7812d97bc8f87004c0a5069c6c94c64af78106 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Tue, 23 Oct 2018 23:54:44 +0100
-Subject: [PATCH 06/30] Fix spurious AD flags in some DNS replies from local
+Subject: [PATCH 06/32] Fix spurious AD flags in some DNS replies from local
  config.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
index c1c674fbfb00b87735cca465cb02be1b30d4a7ec..79347920dcdaf53808ad797c831c361c61bf0145 100644 (file)
@@ -1,7 +1,7 @@
 From 24b87607c1353e94689e8a2190571ab3f3b36f31 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= <pemensik@redhat.com>
 Date: Wed, 24 Oct 2018 22:30:18 +0100
-Subject: [PATCH 07/30] Do not rely on dead code elimination, use array
+Subject: [PATCH 07/32] Do not rely on dead code elimination, use array
  instead. Make options bits derived from size and count. Use size of option
  bits and last supported bit in computation. No new change would be required
  when new options are added. Just change OPT_LAST constant.
index 9c00291d869189a33ce93b1c2330eede745cc23f..766aad2637de5ef202a98b9fb6ebea4c1c7bba15 100644 (file)
@@ -1,7 +1,7 @@
 From 3a5a84cdd1488bad118eeac72d09a60299bca744 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Wed, 31 Oct 2018 21:30:13 +0000
-Subject: [PATCH 08/30] Fix Makefile lines generating UBUS linker config.
+Subject: [PATCH 08/32] Fix Makefile lines generating UBUS linker config.
 
 If arg2 of pkg-wrapper is "--copy", then arg1 is NOT the name of
 the package manager (--copy doesn't invoke it) it's a secondary
index dcbfc3d9fa45939de426ed9b8b915a88f9c4b741..32468ae5a78cfae524d742956d664b3112b579a4 100644 (file)
@@ -1,7 +1,7 @@
 From 122392e0b352507cabb9e982208d35d2e56902e0 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Wed, 31 Oct 2018 22:24:02 +0000
-Subject: [PATCH 09/30] Revert 68f6312d4bae30b78daafcd6f51dc441b8685b1e
+Subject: [PATCH 09/32] Revert 68f6312d4bae30b78daafcd6f51dc441b8685b1e
 
 The above is intended to increase robustness, but actually does the
 opposite. The problem is that by ignoring SERVFAIL messages and hoping
index 2aa4ae7ded507bc46aaeaf18148d0d2fcb4d84e9..78f31d0c2d38f7de5c08e01d4c5359d3c6fbdd74 100644 (file)
@@ -1,7 +1,7 @@
 From 48d12f14c9c0fc8cf943b52774c3892517dd72d4 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Fri, 2 Nov 2018 21:55:04 +0000
-Subject: [PATCH 10/30] Remove the NO_FORK compile-time option, and support for
+Subject: [PATCH 10/32] Remove the NO_FORK compile-time option, and support for
  uclinux.
 
 In an era where everything has an MMU, this looks like
index 9609376ba3fd87ef518f6476c02b6e5e5a8e6389..0b53b30057f19d4cecb9ced79d4eeccfc83a2e94 100644 (file)
@@ -1,7 +1,7 @@
 From 59e470381f84f2fdf0640c7bc67827f3f0c64784 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= <pemensik@redhat.com>
 Date: Fri, 2 Nov 2018 22:39:39 +0000
-Subject: [PATCH 11/30] Free config file values on parsing errors.
+Subject: [PATCH 11/32] Free config file values on parsing errors.
 
 This time I have a little bit more controversal patches. But I think
 still useful. They fixes memory leaks that might occur in some cases.
index d0f59de1ed10b8ac27798b9e5489b89ceacaf67a..7053d032b8372e9775c880b2e915f01f1fb98dd7 100644 (file)
@@ -1,7 +1,7 @@
 From 07e25da5bf26d46aad4f1d2eb19b260789182004 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Sun, 16 Dec 2018 18:21:58 +0000
-Subject: [PATCH 13/30] Treat DS and DNSKEY queries being forwarded the same as
+Subject: [PATCH 13/32] Treat DS and DNSKEY queries being forwarded the same as
  those locally originated.
 
 The queries will not be forwarded to a server for a domain, unless
index a38ca334cb5db86c01dba4775c75c1fc07f758df..2aaf382bad7ef3313fcd9f1d9994fbcfc76cedb8 100644 (file)
@@ -1,7 +1,7 @@
 From 137e9f878fafb38369eab7d9dfe84e4228ff5f89 Mon Sep 17 00:00:00 2001
 From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= <pemensik@redhat.com>
 Date: Sun, 16 Dec 2018 21:25:29 +0000
-Subject: [PATCH 14/30] Fix option parsing errors introduced in
+Subject: [PATCH 14/32] Fix option parsing errors introduced in
  59e470381f84f2fdf0640c7bc67827f3f0c64784
 
 Thanks to Kevin Darbyshire-Bryant for spotting this.
index daf0ed6acacd0ca183bf155fd378a64c0beb4dce..920cf7510a0bea6179daab83f777b028385cacec 100644 (file)
@@ -1,7 +1,7 @@
 From 3becf468bad699bfdcb2d18d553bc72d4c79e23c Mon Sep 17 00:00:00 2001
 From: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
 Date: Wed, 12 Dec 2018 12:00:19 +0000
-Subject: [PATCH 15/30] fix ipv6 ipset bug in master
+Subject: [PATCH 15/32] fix ipv6 ipset bug in master
 MIME-Version: 1.0
 Content-Type: text/plain; charset=UTF-8
 Content-Transfer-Encoding: 8bit
index ac13de4a99282de1020258c4a2a191e82be8fe83..e4e363ba475a593ffd663dcfaee731deebc50931 100644 (file)
@@ -1,7 +1,7 @@
 From b683cf37f9f3dd3dc5d95d621ee75850d559b2e4 Mon Sep 17 00:00:00 2001
 From: Kevin Darbyshire-Bryant <kevin@darbyshire-bryant.me.uk>
 Date: Mon, 10 Dec 2018 10:34:35 +0000
-Subject: [PATCH 16/30] build failure on master with NO_DHCPv6 and fix....
+Subject: [PATCH 16/32] build failure on master with NO_DHCPv6 and fix....
 
 Hi Simon,
 
index ef8b78a9202e36a337441dafc5abe2256cfa008b..1a3b341b9faee4117078a39b515277df1c00b41a 100644 (file)
@@ -1,7 +1,7 @@
 From e7bfd556c079c8b5e7425aed44abc35925b24043 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Mon, 31 Dec 2018 20:51:15 +0000
-Subject: [PATCH 17/30] Alter DHCP address selection after DECLINE in
+Subject: [PATCH 17/32] Alter DHCP address selection after DECLINE in
  consec-addr mode. Avoid offering the same address after a recieving a DECLINE
  message to stop an infinite protocol loop. This has long been done in default
  address allocation mode: this adds similar behaviour when allocaing addresses
index cd9d02237f88295f18c0f20c32ea3dac90299369..e6b456f974e180e8d4d8c6ad3e9149d0fe4a7044 100644 (file)
@@ -1,7 +1,7 @@
 From bde46476ee06c96e821653dfdb8fa11fe7326998 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Mon, 31 Dec 2018 23:28:24 +0000
-Subject: [PATCH 18/30] Tidy all_addr union, merge log and rcode fields.
+Subject: [PATCH 18/32] Tidy all_addr union, merge log and rcode fields.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
 ---
index 883202da85436dce52c9259e4feb616b7a3d0b7e..4854617a0fa99d95e5b418dbe981ef9ddafbb6f6 100644 (file)
@@ -1,7 +1,7 @@
 From 65a01b71bb433c9466e4c78a73a8d8ed218ed4e8 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Mon, 31 Dec 2018 23:56:33 +0000
-Subject: [PATCH 19/30] Tidy address-union handling: move class into explicit
+Subject: [PATCH 19/32] Tidy address-union handling: move class into explicit
  argument.
 
 This moves the class argument to cache-insert into an argument,
index a5f17ec859aef154be849a21b6887dfefbc4801e..deda82fee0a515cb840a06231a881b3092e907a1 100644 (file)
@@ -1,7 +1,7 @@
 From ab194ed7ca433e4e2e8b2ec338bfa4e6aa886a4b Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Tue, 1 Jan 2019 01:35:30 +0000
-Subject: [PATCH 20/30] Futher address union tidying.
+Subject: [PATCH 20/32] Futher address union tidying.
 
 Pass DNSKEY and DS data into cache_insert via the address argument,
 now these data types are included in struct all_addr.
index 4377cc156230b94c9fb40bd71be3d866690dbbdb..360e8a4c04c644416252561eaa452128b2850945 100644 (file)
@@ -1,7 +1,7 @@
 From cc921df9ceac79acf9f1c477d015a3d88275422d Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Wed, 2 Jan 2019 22:48:59 +0000
-Subject: [PATCH 21/30] Remove nested struct/union in cache records and
+Subject: [PATCH 21/32] Remove nested struct/union in cache records and
  all_addr.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
index 92944fabe6c4c0854ff5f0a2a6732816bd95662e..32a02cd56ac80bec415b70cdb95ac36a4b3da765 100644 (file)
@@ -1,7 +1,7 @@
 From 2c594732eb7391e7cfa817598e33e61cab71131f Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Thu, 3 Jan 2019 13:42:03 +0000
-Subject: [PATCH 22/30] File logic bug in cache-marshalling code. Introduced a
+Subject: [PATCH 22/32] File logic bug in cache-marshalling code. Introduced a
  couple of commits back.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
index ecc060e1a99369ace22b06adb259475e0fabb193..48343afeaf0bd127834d66d49a628949a54a15b2 100644 (file)
@@ -1,7 +1,7 @@
 From 2daca52b80afdc92e7c976629a2bf8182335a626 Mon Sep 17 00:00:00 2001
 From: Christian Weiske <cweiske@cweiske.de>
 Date: Thu, 3 Jan 2019 20:10:14 +0000
-Subject: [PATCH 23/30] Fix typo in ra-param man page section.
+Subject: [PATCH 23/32] Fix typo in ra-param man page section.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
 ---
index dec3b82050237c6f175b01c6d99ef8e246262295..d38d30e9d565a0d11256f71baf5ff658dba86c70 100644 (file)
@@ -1,7 +1,7 @@
 From 5b99eae59d59a8e34a7e512059b98bbd803312f2 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Sun, 6 Jan 2019 23:09:50 +0000
-Subject: [PATCH 24/30] Cache SRV records.
+Subject: [PATCH 24/32] Cache SRV records.
 
 Inpsired by a patch from Jeremy Allison, but completely re-rolled
 by srk. All bugs are mine.
index ec4d52d7fd51463a99f05c1c0fd67e79185e324d..424574bbf6a121662b60e7ed87163b2c1fb9aee7 100644 (file)
@@ -1,7 +1,7 @@
 From a90f09db4cc635941a32b973b57e58c662569625 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Wed, 9 Jan 2019 15:08:16 +0000
-Subject: [PATCH 25/30] Fix crash freeing negative SRV cache entries.
+Subject: [PATCH 25/32] Fix crash freeing negative SRV cache entries.
 
 Thanks to Daniel for finding this one.
 
index b84a9281f8b83ecd55d8cf9c3470ce98bd37d7ea..4ca0be455fc4cff1df39786817f127865b87fabc 100644 (file)
@@ -1,7 +1,7 @@
 From 2896e2485e44c04e73a0b7c9f7cbc9c8515d0800 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Wed, 9 Jan 2019 15:12:34 +0000
-Subject: [PATCH 26/30] Check for not(DS or DNSKEY) in
+Subject: [PATCH 26/32] Check for not(DS or DNSKEY) in
  is_outdated_cname_pointer()
 
 Previous check was _for_ IPV4, IPv6 CNAME, and I missed adding SRV.
index 180a030020937e48e8a6f97b5fb4f3f45743cf59..63d5baa4cd7c2059f0a3f3a2be4e39d29588f81a 100644 (file)
@@ -1,7 +1,7 @@
 From 9c0d445ef4abffa2b9342ad65e85ef425c1f83bb Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Wed, 9 Jan 2019 17:57:56 +0000
-Subject: [PATCH 27/30] Fix e7bfd556c079c8b5e7425aed44abc35925b24043 to
+Subject: [PATCH 27/32] Fix e7bfd556c079c8b5e7425aed44abc35925b24043 to
  actually work.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
index ed8170c59b7aa0af9e15f96a8cc2c5262a9a655f..8aa69a743b82cd902a5c851caa15f3ed57a187bf 100644 (file)
@@ -1,7 +1,7 @@
 From 4bf62f616b82fad7a7f91195b0204dd64d79a35c Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Thu, 10 Jan 2019 21:54:22 +0000
-Subject: [PATCH 28/30] Tidy cache_blockdata_free()
+Subject: [PATCH 28/32] Tidy cache_blockdata_free()
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
 ---
index d8ae0e7910de6c8cad8b2383afd2049f2bbfa09f..e02bd11d2302dc73569858abfcc64bd0b95cb99c 100644 (file)
@@ -1,7 +1,7 @@
 From f8c77edbdffb8ada7753ea9fa104f0f6da70cfe3 Mon Sep 17 00:00:00 2001
 From: Simon Kelley <simon@thekelleys.org.uk>
 Date: Thu, 10 Jan 2019 21:58:18 +0000
-Subject: [PATCH 29/30] Fix removal of DHCP_CLIENT_MAC options from DHCPv6
+Subject: [PATCH 29/32] Fix removal of DHCP_CLIENT_MAC options from DHCPv6
  relay replies.
 
 Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
index 265bd3fc9efb70437114b63c2a2909bb4f323d78..00f2102fde1b0fd2a1c5a1fdf1722603d767076d 100644 (file)
@@ -1,7 +1,7 @@
 From 18eac67c0a15b673c8d27002c248651b308093e4 Mon Sep 17 00:00:00 2001
 From: Steven Siloti <ssiloti@gmail.com>
 Date: Sun, 13 Jan 2019 22:56:36 +0000
-Subject: [PATCH 30/30] Fix entries in /etc/hosts disabling static leases.
+Subject: [PATCH 30/32] Fix entries in /etc/hosts disabling static leases.
 
 It is possible for a config entry to have one address family specified by a
 dhcp-host directive and the other added from /etc/hosts. This is especially
diff --git a/package/network/services/dnsmasq/patches/0031-Fix-missing-braces-in-8eac67c0a15b673c8d27002c248651.patch b/package/network/services/dnsmasq/patches/0031-Fix-missing-braces-in-8eac67c0a15b673c8d27002c248651.patch
new file mode 100644 (file)
index 0000000..928c6ee
--- /dev/null
@@ -0,0 +1,28 @@
+From d2d49907435433001ab00698a3e9ca2a7b5b3236 Mon Sep 17 00:00:00 2001
+From: Steven Siloti <ssiloti@gmail.com>
+Date: Thu, 17 Jan 2019 22:52:13 +0000
+Subject: [PATCH 31/32] Fix missing braces in
+ 8eac67c0a15b673c8d27002c248651b308093e4
+
+Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
+---
+ src/dhcp-common.c | 2 ++
+ 1 file changed, 2 insertions(+)
+
+--- a/src/dhcp-common.c
++++ b/src/dhcp-common.c
+@@ -371,12 +371,14 @@ void dhcp_update_configs(struct dhcp_con
+   int prot = AF_INET;
+   for (config = configs; config; config = config->next)
++  {
+     if (config->flags & CONFIG_ADDR_HOSTS)
+       config->flags &= ~(CONFIG_ADDR | CONFIG_ADDR_HOSTS);
+ #ifdef HAVE_DHCP6
+     if (config->flags & CONFIG_ADDR6_HOSTS)
+       config->flags &= ~(CONFIG_ADDR6 | CONFIG_ADDR6_HOSTS);
+ #endif
++  }
+ #ifdef HAVE_DHCP6 
+  again:  
diff --git a/package/network/services/dnsmasq/patches/0031-fix-previous-commit.patch b/package/network/services/dnsmasq/patches/0031-fix-previous-commit.patch
deleted file mode 100644 (file)
index d985c4a..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-From f52bb5be437ab33d7cd10f0ff1cdf0bb86857cf7 Mon Sep 17 00:00:00 2001
-From: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
-Date: Wed, 16 Jan 2019 09:48:07 +0000
-Subject: [PATCH 31/31] fix previous commit
-
-Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
----
- src/dhcp-common.c | 2 ++
- 1 file changed, 2 insertions(+)
-
---- a/src/dhcp-common.c
-+++ b/src/dhcp-common.c
-@@ -371,12 +371,14 @@ void dhcp_update_configs(struct dhcp_con
-   int prot = AF_INET;
-   for (config = configs; config; config = config->next)
-+  {
-     if (config->flags & CONFIG_ADDR_HOSTS)
-       config->flags &= ~(CONFIG_ADDR | CONFIG_ADDR_HOSTS);
- #ifdef HAVE_DHCP6
-     if (config->flags & CONFIG_ADDR6_HOSTS)
-       config->flags &= ~(CONFIG_ADDR6 | CONFIG_ADDR6_HOSTS);
- #endif
-+  }
- #ifdef HAVE_DHCP6 
-  again:  
diff --git a/package/network/services/dnsmasq/patches/0032-Change-read_leases-to-skip-invalid-entries.patch b/package/network/services/dnsmasq/patches/0032-Change-read_leases-to-skip-invalid-entries.patch
new file mode 100644 (file)
index 0000000..bbaed87
--- /dev/null
@@ -0,0 +1,61 @@
+From 28cfe36e1eee9d2c234e0256ad459956b415a3bb Mon Sep 17 00:00:00 2001
+From: Brian Haley <haleyb.dev@gmail.com>
+Date: Thu, 17 Jan 2019 23:21:23 +0000
+Subject: [PATCH 32/32] Change read_leases() to skip invalid entries.
+
+There's no reason to stop reading the existing lease file
+when dnsmasq is started and an invalid entry is found, it
+can just be ignored.  This was fallout from an Openstack
+bug where the file was being written incorrectly with []
+around IPv6 addresses.
+
+Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
+---
+ src/lease.c | 22 +++++++++++++++-------
+ 1 file changed, 15 insertions(+), 7 deletions(-)
+
+--- a/src/lease.c
++++ b/src/lease.c
+@@ -60,8 +60,13 @@ static int read_leases(time_t now, FILE
+       
+       if (fscanf(leasestream, " %64s %255s %764s",
+                  daemon->namebuff, daemon->dhcp_buff, daemon->packet) != 3)
+-        return 0;
+-      
++        {
++          my_syslog(MS_DHCP | LOG_WARNING, _("ignoring invalid line in lease database: %s %s %s %s ..."),
++                    daemon->dhcp_buff3, daemon->dhcp_buff2,
++                    daemon->namebuff, daemon->dhcp_buff);
++          continue;
++        }
++              
+       if (inet_pton(AF_INET, daemon->namebuff, &addr.addr4))
+         {
+           if ((lease = lease4_allocate(addr.addr4)))
+@@ -92,7 +97,12 @@ static int read_leases(time_t now, FILE
+         }
+ #endif
+       else
+-        return 0;
++        {
++          my_syslog(MS_DHCP | LOG_WARNING, _("ignoring invalid line in lease database, bad address: %s"),
++                    daemon->namebuff);
++          continue;
++        }
++      
+       if (!lease)
+         die (_("too many stored leases"), NULL, EC_MISC);
+@@ -172,10 +182,8 @@ void lease_init(time_t now)
+   if (leasestream)
+     {
+       if (!read_leases(now, leasestream))
+-      my_syslog(MS_DHCP | LOG_ERR, _("failed to parse lease database, invalid line: %s %s %s %s ..."),
+-                daemon->dhcp_buff3, daemon->dhcp_buff2,
+-                daemon->namebuff, daemon->dhcp_buff);
+-
++      my_syslog(MS_DHCP | LOG_ERR, _("failed to parse lease database cleanly"));
++      
+       if (ferror(leasestream))
+       die(_("failed to read lease file %s: %s"), daemon->lease_file, EC_FILE);
+     }