diff --git a/bind-dyndb-ldap-11.6-bind-9.16.10.patch b/bind-dyndb-ldap-11.6-bind-9.16.10.patch new file mode 100644 index 0000000..717c81e --- /dev/null +++ b/bind-dyndb-ldap-11.6-bind-9.16.10.patch @@ -0,0 +1,38 @@ +From 2ddd4bf55e325071566aa1c78e3681c3239895da Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= +Date: Mon, 11 Jan 2021 21:39:25 +0100 +Subject: [PATCH] Add compatibility with BIND 9.16.10 API change + +One parameter was added to function used internally by plugin. Nothing +like -nsec3param auto is supported by LDAP plugin. It is safe to set +resalt false always. Salt can be changed via LDAP, but has to be +specified manually. +--- + src/ldap_helper.c | 7 +++++++ + 1 file changed, 7 insertions(+) + +diff --git a/src/ldap_helper.c b/src/ldap_helper.c +index a81a9d228..3b4ae5c67 100644 +--- a/src/ldap_helper.c ++++ b/src/ldap_helper.c +@@ -1792,10 +1792,17 @@ zone_master_reconfigure_nsec3param(settings_set_t *zone_settings, + dns_rdatatype_nsec3param, origin, nsec3p_str, + &nsec3p_rdata)); + CHECK(dns_rdata_tostruct(nsec3p_rdata, &nsec3p_rr, NULL)); ++#if LIBDNS_VERSION_MAJOR > 1609 ++ CHECK(dns_zone_setnsec3param(secure, nsec3p_rr.hash, nsec3p_rr.flags, ++ nsec3p_rr.iterations, ++ nsec3p_rr.salt_length, nsec3p_rr.salt, ++ true, false)); ++#else + CHECK(dns_zone_setnsec3param(secure, nsec3p_rr.hash, nsec3p_rr.flags, + nsec3p_rr.iterations, + nsec3p_rr.salt_length, nsec3p_rr.salt, + true)); ++#endif + + cleanup: + if (nsec3p_rdata != NULL) { +-- +2.26.2 + diff --git a/bind-dyndb-ldap-11.6-bind-9.16.11.patch b/bind-dyndb-ldap-11.6-bind-9.16.11.patch new file mode 100644 index 0000000..b190ba0 --- /dev/null +++ b/bind-dyndb-ldap-11.6-bind-9.16.11.patch @@ -0,0 +1,38 @@ +From f4aec4d37447cc274b90c129ea15a008473ed02d Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Petr=20Men=C5=A1=C3=ADk?= +Date: Thu, 21 Jan 2021 17:30:54 +0100 +Subject: [PATCH] Yet another change to support BIND 9.16.11 API change + +Another change with another release, new parameter is added again. +Add another ifdef to keep compatibility with both versions. +--- + src/zone.c | 5 +++++ + 1 file changed, 5 insertions(+) + +diff --git a/src/zone.c b/src/zone.c +index d0b71b194..7ce1769b3 100644 +--- a/src/zone.c ++++ b/src/zone.c +@@ -17,6 +17,7 @@ + #include + + #include "util.h" ++#include "config.h" + + /** + * Write given diff to zone journal. Journal will be created +@@ -61,7 +62,11 @@ zone_soaserial_updatetuple(dns_updatemethod_t method, dns_difftuple_t *soa_tuple + REQUIRE(soa_tuple->rdata.type == dns_rdatatype_soa); + + serial = dns_soa_getserial(&soa_tuple->rdata); ++#if LIBDNS_VERSION_MAJOR >= 1611 ++ serial = dns_update_soaserial(serial, method, NULL); ++#else + serial = dns_update_soaserial(serial, method); ++#endif + dns_soa_setserial(serial, &soa_tuple->rdata); + if (new_serial != NULL) + *new_serial = serial; +-- +2.26.2 + diff --git a/bind-dyndb-ldap.spec b/bind-dyndb-ldap.spec index 86a0340..13e6197 100644 --- a/bind-dyndb-ldap.spec +++ b/bind-dyndb-ldap.spec @@ -12,7 +12,7 @@ Name: bind-dyndb-ldap Version: 11.6 -Release: 3%{?dist} +Release: 6%{?dist} Summary: LDAP back-end plug-in for BIND License: GPLv2+ @@ -21,6 +21,8 @@ Source0: https://releases.pagure.org/%{name}/%{name}-%{VERSION}.tar.bz2 Source1: https://releases.pagure.org/%{name}/%{name}-%{VERSION}.tar.bz2.asc Patch1: bind-dyndb-ldap-11.6-bind-9.16.9.patch +Patch2: bind-dyndb-ldap-11.6-bind-9.16.10.patch +Patch3: bind-dyndb-ldap-11.6-bind-9.16.11.patch BuildRequires: bind-devel >= %{bind_version}, bind-lite-devel >= %{bind_version} BuildRequires: krb5-devel @@ -54,12 +56,11 @@ off of your LDAP server. autoreconf -fiv export BIND9_CFLAGS='-I /usr/include/bind9 -DHAVE_TLS -DHAVE_THREAD_LOCAL' %configure -make %{?_smp_mflags} +%make_build %install -rm -rf %{buildroot} -make install DESTDIR=%{buildroot} +%make_install mkdir -m 770 -p %{buildroot}/%{_localstatedir}/named/dyndb-ldap # Remove unwanted files @@ -117,6 +118,17 @@ sed -i.bak -e "$SEDSCRIPT" /etc/named.conf %changelog +* Fri Jan 22 2021 Petr Menšík - 11.6-6 +- Rebuilt for BIND 9.16.11 + +* Fri Jan 15 2021 Petr Menšík - 11.6-5 +- Rebuilt for BIND 9.16.10 + +* Tue Jan 12 2021 Petr Menšík - 11.6-4 +- Support BIND 9.16.10 +- Use make macros +- https://fedoraproject.org/wiki/Changes/UseMakeBuildInstallMacro + * Thu Dec 17 2020 Alexander Bokovoy - 11.6-3 - Both require bind and require it for pre-install script - Resolves: rhbz#1902811