diff --git a/SOURCES/dnsmasq-2.66-numeric-hostnames.patch b/SOURCES/dnsmasq-2.66-numeric-hostnames.patch new file mode 100644 index 0000000..a1d36d9 --- /dev/null +++ b/SOURCES/dnsmasq-2.66-numeric-hostnames.patch @@ -0,0 +1,20 @@ +diff --git a/src/util.c b/src/util.c +index af4031c..759099c 100644 +--- a/src/util.c ++++ b/src/util.c +@@ -151,12 +151,12 @@ int legal_hostname(char *name) + /* check for legal char a-z A-Z 0-9 - _ . */ + { + if ((c >= 'A' && c <= 'Z') || +- (c >= 'a' && c <= 'z')) ++ (c >= 'a' && c <= 'z') || ++ (c >= '0' && c <= '9')) + continue; + + if (!first && +- ((c >= '0' && c <= '9') || +- c == '-' || c == '_')) ++ (c == '-' || c == '_')) + continue; + + /* end of hostname part */ diff --git a/SPECS/dnsmasq.spec b/SPECS/dnsmasq.spec index 82b4b11..93ec46b 100644 --- a/SPECS/dnsmasq.spec +++ b/SPECS/dnsmasq.spec @@ -13,7 +13,7 @@ Name: dnsmasq Version: 2.66 -Release: 14%{?extraversion}%{?dist} +Release: 14%{?extraversion}%{?dist}.1 Summary: A lightweight DHCP/caching DNS server Group: System Environment/Daemons @@ -67,6 +67,8 @@ Patch19: %{name}-2.66-Set-SOREUSEADDR-as-well-as-SOREUSEPORT-on-DHCP-sock Patch20: %{name}-2.66-Support-IPv6-assignment-based-on-MAC-for-DHCPv6.patch # https://bugzilla.redhat.com/show_bug.cgi?id=1232677 Patch21: %{name}-2.66-dhcp-v4-v6.patch +# https://bugzilla.redhat.com/show_bug.cgi?id=1358427 +Patch23: %{name}-2.66-numeric-hostnames.patch BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n) @@ -125,6 +127,7 @@ query/remove a DHCP server's leases. %patch19 -p1 -b .reuseport %patch20 -p1 %patch21 -p1 +%patch23 -p1 # use /var/lib/dnsmasq instead of /var/lib/misc for file in dnsmasq.conf.example man/dnsmasq.8 man/es/dnsmasq.8 src/config.h; do @@ -205,6 +208,9 @@ rm -rf $RPM_BUILD_ROOT %{_mandir}/man1/dhcp_* %changelog +* Tue Aug 30 2016 Pavel Šimerda - 2.66-14.1 +- Resolves: #1371460 - dhcp errors with hostnames beginning with numbers + * Thu Jun 25 2015 Pavel Šimerda - 2.66-14 - Resolves: #1232677 - handle IPv4 and IPv6 host entries properly