Blame SPECS/bind-dyndb-ldap.spec

c96fbb
%define VERSION %{version}
c96fbb
c96fbb
%define bind_version 32:9.11.1-1.P1
c96fbb
c96fbb
Name:           bind-dyndb-ldap
c96fbb
Version:        11.1
c96fbb
Release:        7%{?dist}
c96fbb
Summary:        LDAP back-end plug-in for BIND
c96fbb
c96fbb
Group:          System Environment/Libraries
c96fbb
License:        GPLv2+
c96fbb
URL:            https://releases.pagure.org/bind-dyndb-ldap
c96fbb
Source0:        https://releases.pagure.org/%{name}/%{name}-%{VERSION}.tar.bz2
c96fbb
Source1:        https://releases.pagure.org/%{name}/%{name}-%{VERSION}.tar.bz2.asc
c96fbb
Patch1:         bind-dyndb-ldap-pemensik-0002-Treat-passwords-like-ordinary-text-bind-does-not-sup.patch
c96fbb
Patch2:         bind-dyndb-ldap-pemensik-0003-Replace-unsupported-autoreallocating-buffer-by-custo.patch
c96fbb
Patch3:         bind-dyndb-ldap-tkrizek-0005-Setting-skip-unconfigured-values.patch
c96fbb
Patch4:         bind-dyndb-ldap-tkrizek-0006-Coverity-fix-REVERSE_INULL-for-pevent-inst.patch
c96fbb
Patch5:         bind-dyndb-ldap-pemensik-0007-Add-empty-callback-for-getsize.patch
c96fbb
Patch6:         bind-dyndb-ldap-pemensik-0008-Support-for-BIND-9.11.3.patch
c96fbb
Patch7:         bind-dyndb-ldap-pemensik-0009-Support-for-BIND-9.11.5.patch
c96fbb
Patch8:         bind-dyndb-ldap-pemensik-0010-Use-correct-dn-value.patch
c96fbb
Patch9:         bind-dyndb-ldap-template-attribute-defaults.patch
c96fbb
c96fbb
BuildRoot:      %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
c96fbb
c96fbb
BuildRequires:  bind-devel >= %{bind_version}, bind-lite-devel >= %{bind_version}, bind-pkcs11-devel >= %{bind_version}
c96fbb
BuildRequires:  krb5-devel
c96fbb
BuildRequires:  openldap-devel
c96fbb
BuildRequires:  openssl-devel
c96fbb
BuildRequires:  libuuid-devel
c96fbb
BuildRequires:  automake, autoconf, libtool
c96fbb
c96fbb
Requires:       bind-pkcs11 >= %{bind_version}, bind-pkcs11-utils >= %{bind_version}
c96fbb
Requires(post):  sed
c96fbb
c96fbb
%description
c96fbb
This package provides an LDAP back-end plug-in for BIND. It features
c96fbb
support for dynamic updates and internal caching, to lift the load
c96fbb
off of your LDAP server.
c96fbb
c96fbb
c96fbb
%prep
c96fbb
%autosetup -p1
c96fbb
c96fbb
%build
c96fbb
autoreconf -fiv
c96fbb
%configure --disable-werror
c96fbb
make %{?_smp_mflags}
c96fbb
c96fbb
c96fbb
%install
c96fbb
rm -rf %{buildroot}
c96fbb
make install DESTDIR=%{buildroot}
c96fbb
mkdir -m 770 -p %{buildroot}/%{_localstatedir}/named/dyndb-ldap
c96fbb
c96fbb
# Remove unwanted files
c96fbb
rm %{buildroot}%{_libdir}/bind/ldap.la
c96fbb
rm -r %{buildroot}%{_datadir}/doc/%{name}
c96fbb
c96fbb
c96fbb
%post
c96fbb
# Transform named.conf if it still has old-style API.
c96fbb
PLATFORM=$(uname -m) 
c96fbb
c96fbb
if [ $PLATFORM == "x86_64" ] ; then
c96fbb
    LIBPATH=/usr/lib64
c96fbb
else
c96fbb
    LIBPATH=/usr/lib
c96fbb
fi
c96fbb
c96fbb
# The following sed script:
c96fbb
#   - scopes the named.conf changes to dynamic-db
c96fbb
#   - replaces arg "name value" syntax with name "value"
c96fbb
#   - changes dynamic-db header to dyndb
c96fbb
#   - uses the new way the define path to the library
c96fbb
#   - removes no longer supported arguments (library, cache_ttl,
c96fbb
#       psearch, serial_autoincrement, zone_refresh)
c96fbb
while read -r PATTERN
c96fbb
do
c96fbb
    SEDSCRIPT+="$PATTERN"
c96fbb
done <
c96fbb
/^\s*dynamic-db/,/};/ {
c96fbb
c96fbb
  s/\(\s*\)arg\s\+\(["']\)\([a-zA-Z_]\+\s\)/\1\3\2/g;
c96fbb
c96fbb
  s/^dynamic-db/dyndb/;
c96fbb
c96fbb
  s@\(dyndb "[^"]\+"\)@\1 "$LIBPATH/bind/ldap.so"@;
c96fbb
  s@\(dyndb '[^']\+'\)@\1 '$LIBPATH/bind/ldap.so'@;
c96fbb
c96fbb
  /\s*library[^;]\+;/d;
c96fbb
  /\s*cache_ttl[^;]\+;/d;
c96fbb
  /\s*psearch[^;]\+;/d;
c96fbb
  /\s*serial_autoincrement[^;]\+;/d;
c96fbb
  /\s*zone_refresh[^;]\+;/d;
c96fbb
}
c96fbb
EOF
c96fbb
c96fbb
sed -i.bak -e "$SEDSCRIPT" /etc/named.conf
c96fbb
c96fbb
%clean
c96fbb
rm -rf %{buildroot}
c96fbb
c96fbb
c96fbb
%files
c96fbb
%defattr(-,root,root,-)
c96fbb
%doc NEWS README.md COPYING doc/{example,schema}.ldif
c96fbb
%dir %attr(770, root, named) %{_localstatedir}/named/dyndb-ldap
c96fbb
%{_libdir}/bind/ldap.so
c96fbb
c96fbb
c96fbb
%changelog
c96fbb
* Wed Sep 04 2019 Alexander Bokovoy <abokovoy@redhat.com> - 11.1-7
c96fbb
- Fix attribute templating in case of a missing default value
c96fbb
- Resolves: rhbz#1748904
c96fbb
c96fbb
* Tue Feb 12 2019 Petr Menšík <pemensik@redhat.com> - 11.1-6
c96fbb
- Bump BIND version and fix library dependecies
c96fbb
- Rebuild for bind 9.11.3. Minor tweaks to compile.
c96fbb
- Support for bind 9.11.5 headers
c96fbb
c96fbb
* Mon May 28 2018 Petr Menšík <pemensik@redhat.com> - 11.1-5
c96fbb
- Resolves: #1580389 depend on bind with writeable home
c96fbb
c96fbb
* Wed Jul 12 2017 Tomas Krizek <tkrizek@redhat.com> - 11.1-4
c96fbb
- Resolves: #1469563 required bind version doesn't have the dyndb interface
c96fbb
c96fbb
* Wed Apr 26 2017 Tomas Krizek <tkrizek@redhat.com> - 11.1-3
c96fbb
- resolves: #1436268 crash when server_id is not present in named.conf
c96fbb
- coverity fixes
c96fbb
c96fbb
* Wed Mar 15 2017 Tomas Krizek <tkrizek@redhat.com> - 11.1-2
c96fbb
- bump NVR to fix bind dependencies
c96fbb
c96fbb
* Wed Mar 15 2017 Tomas Krizek <tkrizek@redhat.com> - 11.1-1
c96fbb
- update to letest upstream version
c96fbb
- resolves: #1393889 Rebase to bind-dyndb-ldap 11+
c96fbb
- resolves: #1165796 bind-dyndb-ldap crashes if server is shutting down and connection to LDAP is down
c96fbb
- resolves: #1413805 bind-dyndb-ldap default schema is shipped with syntax error
c96fbb
c96fbb
* Wed Sep 21 2016 Petr Spacek <pspacek@redhat.com> - 10.0-5
c96fbb
- resolves: #1376851 Unable to set named_write_master_zones boolean on upgrade
c96fbb
c96fbb
* Tue Aug 16 2016 Petr Spacek <pspacek@redhat.com> - 10.0-4
c96fbb
- resolves: #1366565 Deletion of DNS root zone breaks global forwarding
c96fbb
c96fbb
* Thu Jul 28 2016 Petr Spacek <pspacek@redhat.com> - 10.0-3
c96fbb
- rebuild against redhat-rpm-config-9.1.0-71.el7 to fix /usr/share/doc naming
c96fbb
- related: #1057327
c96fbb
c96fbb
* Wed Jul 27 2016 Petr Spacek <pspacek@redhat.com> - 10.0-2
c96fbb
- resolves: #1359220 prevent crash while reloading previously invalid
c96fbb
  but now valid DNS zone
c96fbb
c96fbb
* Tue Jun 21 2016 Petr Spacek <pspacek@redhat.com> - 10.0-1
c96fbb
- update to latest upstream version
c96fbb
- resolves: #1292145 Rebase bind-dyndb-ldap to latest upstream version
c96fbb
c96fbb
* Thu May 12 2016 Petr Spacek <pspacek@redhat.com> - 9.0-1
c96fbb
- update to latest upstream version
c96fbb
- related: #1292145 Rebase bind-dyndb-ldap to latest upstream version
c96fbb
c96fbb
* Tue Jun 23 2015 Petr Spacek <pspacek redhat com> - 8.0-1
c96fbb
- update to latest upstream version
c96fbb
- resolves: #1204110 Rebase bind-dyndb-ldap to latest upstream version
c96fbb
c96fbb
* Mon Jun 08 2015 Petr Spacek <pspacek redhat com> - 7.99-1
c96fbb
- preliminary update to latests snapshot of upstream Git: 158e95e (#1204110)
c96fbb
- resolves: #829395  DNSSEC support
c96fbb
- resolves: #1139776 LDAP MODRDN (rename) is not supported
c96fbb
- resolves: #1139778 Records deleted when connection to LDAP is down are not refreshed properly
c96fbb
- resolves: #1184065 PTR record synchronization for A/AAAA record tuple can fail mysteriously
c96fbb
- resolves: #1207539 Add support for TLSA resource records (DANE)
c96fbb
- resolves: #1207540 Plugin will crash if idnsForwardZone object is in the wrong place
c96fbb
- resolves: #1207541 Generic support for unknown DNS RR types (RFC 3597)
c96fbb
c96fbb
* Tue Dec 02 2014 Petr Spacek <pspacek redhat com> - 6.0-2
c96fbb
- fix bug 1161635: send DNS NOTIFY message after any modification to the zone
c96fbb
- fix bug 1168131: crash caused by interaction between forward and master zones
c96fbb
c96fbb
* Tue Sep 23 2014 Petr Spacek <pspacek redhat com> - 6.0-1
c96fbb
- update to 6.0
c96fbb
- resolves bugs 1138317, 1144599, 1142176
c96fbb
c96fbb
* Fri Sep 12 2014 Petr Spacek <pspacek redhat com> - 5.3-1
c96fbb
- update to 5.3
c96fbb
- fixes several random crashes
c96fbb
c96fbb
* Mon Sep 08 2014 Petr Spacek <pspacek redhat com> - 5.2-1
c96fbb
- update to 5.2
c96fbb
- adds DNSSEC support and supports root zone in LDAP
c96fbb
- idnsZoneActive attribute is not supported anymore
c96fbb
c96fbb
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 3.5-4
c96fbb
- Mass rebuild 2014-01-24
c96fbb
c96fbb
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 3.5-3
c96fbb
- Mass rebuild 2013-12-27
c96fbb
c96fbb
* Tue Sep 24 2013 Tomas Hozza <thozza@redhat.com> 3.5-2
c96fbb
- rebuild against new bind (Related: #1010200) (#1011118)
c96fbb
c96fbb
* Thu Jul 18 2013 Petr Spacek <pspacek redhat com> 3.5-1
c96fbb
- update to 3.5
c96fbb
c96fbb
* Tue Jun 25 2013 Petr Spacek <pspacek redhat com> 3.4-1
c96fbb
- update to 3.4
c96fbb
c96fbb
* Tue Jun 04 2013 Petr Spacek <pspacek redhat com> 3.3-1
c96fbb
- update to 3.3
c96fbb
- patch bind-dyndb-ldap-tbabej-0001-Build-fixes-for-Fedora-19.patch merged
c96fbb
c96fbb
* Tue May 14 2013 Petr Spacek <pspacek redhat com> 3.2-1
c96fbb
- update to 3.2
c96fbb
c96fbb
* Tue Apr 16 2013 Adam Tkac <atkac redhat com> 3.1-2
c96fbb
- rebuild against new bind
c96fbb
- build with --disable-werror
c96fbb
c96fbb
* Fri Apr 12 2013 Petr Spacek <pspacek redhat com> 3.1-1
c96fbb
- update to 3.1
c96fbb
c96fbb
* Tue Apr 02 2013 Petr Spacek <pspacek redhat com> 3.0-1
c96fbb
- update to 3.0
c96fbb
c96fbb
* Tue Mar 26 2013 Petr Spacek <pspacek redhat com> 2.6-1
c96fbb
- update to 2.6
c96fbb
c96fbb
* Mon Feb 04 2013 Petr Spacek <pspacek redhat com> 2.5-1
c96fbb
- update to 2.5
c96fbb
c96fbb
* Tue Jan 15 2013 Petr Spacek <pspacek redhat com> 2.4-1
c96fbb
- update to 2.4
c96fbb
c96fbb
* Thu Nov  8 2012 Petr Spacek <pspacek redhat com> 2.3-2
c96fbb
- rebuild with proper changelog
c96fbb
c96fbb
* Thu Nov  8 2012 Petr Spacek <pspacek redhat com> 2.3-1
c96fbb
- update to 2.3
c96fbb
c96fbb
* Mon Oct 29 2012 Adam Tkac <atkac redhat com> 2.1-1
c96fbb
- update to 2.1
c96fbb
c96fbb
* Thu Oct 11 2012 Adam Tkac <atkac redhat com> 2.0-0.3.20121009git6a86b1
c96fbb
- rebuild against new bind-libs
c96fbb
c96fbb
* Tue Oct  9 2012 Petr Spacek <pspacek redhat com> 2.0-0.2.20121009git6a86b1
c96fbb
- update to the latest master
c96fbb
c96fbb
* Fri Sep 21 2012 Adam Tkac <atkac redhat com> 2.0-0.1.20120921git7710d89
c96fbb
- update to the latest master
c96fbb
- bind-dyndb-ldap110-master.patch was merged
c96fbb
c96fbb
* Thu Aug 16 2012 Adam Tkac <atkac redhat com> 1.1.0-0.16.rc1
c96fbb
- update to the latest git
c96fbb
c96fbb
* Thu Aug 02 2012 Adam Tkac <atkac redhat com> 1.1.0-0.15.rc1
c96fbb
- update to the latest git
c96fbb
  - fix for CVE-2012-3429 has been merged
c96fbb
c96fbb
* Thu Aug 02 2012 Adam Tkac <atkac redhat com> 1.1.0-0.14.rc1
c96fbb
- fix CVE-2012-3429
c96fbb
c96fbb
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.1.0-0.13.rc1
c96fbb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
c96fbb
c96fbb
* Thu Jun 07 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.12.rc1
c96fbb
- update to the latest master (#827401)
c96fbb
c96fbb
* Thu Apr 26 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.11.rc1
c96fbb
- update to 1.1.0rc1 (CVE-2012-2134)
c96fbb
c96fbb
* Tue Mar 27 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.10.b2
c96fbb
- update to 1.1.0b2
c96fbb
c96fbb
* Tue Mar 06 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.9.b1
c96fbb
- update to 1.1.0b1
c96fbb
c96fbb
* Mon Feb 13 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.8.a2
c96fbb
- update to 1.1.0a2
c96fbb
c96fbb
* Thu Feb 02 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.7.a1
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Wed Jan 18 2012 Adam Tkac <atkac redhat com> - 1.1.0-0.6.a1
c96fbb
- update to 1.1.0a1
c96fbb
c96fbb
* Thu Jan 12 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 1.0.0-0.5.rc1
c96fbb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
c96fbb
c96fbb
* Mon Nov 14 2011 Adam Tkac <atkac redhat com> - 1.0.0-0.4.rc1
c96fbb
- update to 1.0.0rc1
c96fbb
c96fbb
* Mon Nov 14 2011 Adam Tkac <atkac redhat com> - 1.0.0-0.3.b1
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Fri Sep 09 2011 Adam Tkac <atkac redhat com> - 1.0.0-0.2.b1
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Wed Aug 31 2011 Adam Tkac <atkac redhat com> - 1.0.0-0.1.b1
c96fbb
- update to 1.0.0b1 (psearch + bugfixes)
c96fbb
- bind-dyndb-ldap-rh727856.patch merged
c96fbb
c96fbb
* Wed Aug 03 2011 Adam Tkac <atkac redhat com> - 0.2.0-4
c96fbb
- fix race condition in semaphore_wait (#727856)
c96fbb
c96fbb
* Mon Feb 21 2011 Adam Tkac <atkac redhat com> - 0.2.0-3
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Mon Feb 07 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.2.0-2
c96fbb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
c96fbb
c96fbb
* Wed Jan 12 2011 Adam Tkac <atkac redhat com> - 0.2.0-1
c96fbb
- update to 0.2.0
c96fbb
- patches merged
c96fbb
  - 0001-Bugfix-Improve-LDAP-schema-to-be-loadable-by-OpenLDA.patch
c96fbb
  - 0004-Bugfix-Fix-loading-of-child-zones-from-LDAP.patch
c96fbb
c96fbb
* Wed Dec 15 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.17.b
c96fbb
- fix LDAP schema (#622604)
c96fbb
- load child zones from LDAP correctly (#622617)
c96fbb
c96fbb
* Fri Oct 22 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.16.b
c96fbb
- build with correct RPM_OPT_FLAGS (#645529)
c96fbb
c96fbb
* Wed Oct 20 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.15.b
c96fbb
- use "isc-config.sh" utility to get correct BIND9 CFLAGS
c96fbb
c96fbb
* Thu Sep 30 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.14.b
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Fri Aug 27 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.13.b
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Tue Aug 17 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.12.b
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Tue Aug 03 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.11.b
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Mon May 31 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.10.b
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Wed Mar 24 2010 Martin Nagy <mnagy@redhat.com> - 0.1.0-0.9.b
c96fbb
- update to the latest upstream release
c96fbb
c96fbb
* Thu Jan 28 2010 Adam Tkac <atkac redhat com> - 0.1.0-0.8.a1.20091210git
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Tue Dec 15 2009 Adam Tkac <atkac redhat com> - 0.1.0-0.7.a1.20091210git
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Thu Dec 10 2009 Martin Nagy <mnagy@redhat.com> - 0.1.0-0.6.a1.20091210git
c96fbb
- update to the latest git snapshot
c96fbb
- change upstream URL, project moved to fedorahosted
c96fbb
- change license to GPL version 2 or later
c96fbb
- add epoch to versioned requires
c96fbb
- add krb5-devel to the list of build requires
c96fbb
c96fbb
* Tue Dec 01 2009 Adam Tkac <atkac redhat com> - 0.1.0-0.5.a1
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Thu Nov 26 2009 Adam Tkac <atkac redhat com> - 0.1.0-0.4.a1
c96fbb
- rebuild against new bind
c96fbb
c96fbb
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.1.0-0.3.a1
c96fbb
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
c96fbb
c96fbb
* Fri Jun 19 2009 Caolán McNamara <caolanm@redhat.com> - 0.1.0-0.2.a1
c96fbb
- rebuild for dependencies
c96fbb
c96fbb
* Sun May 03 2009 Martin Nagy <mnagy@redhat.com> - 0.1.0-0.1.a1
c96fbb
- initial packaging