update to isc-bind-9.18.1

This commit is contained in:
sthen 2022-04-12 20:33:51 +00:00
parent c6744774ed
commit 21dc7eb899
11 changed files with 107 additions and 195 deletions

View File

@ -2,7 +2,7 @@ COMMENT= Berkeley Internet Name Daemon: DNS server and tools
# Second digits: odd numbers devel, even numbers stable,
# ESV branched occasionally. 9.16.x is ESV.
V= 9.16.27
V= 9.18.1
SUBST_VARS+= V
PORTROACH= limitw:1,even
EXTRACT_SUFX= .tar.xz
@ -21,8 +21,8 @@ MAINTAINER= Stuart Henderson <stu.ports@spacehopper.org>
# MPL 2.0
PERMIT_PACKAGE= Yes
WANTLIB += c crypto execinfo iconv idn2 json-c lzma m pthread ssl
WANTLIB += unistring uv xml2 z
WANTLIB += c crypto execinfo iconv idn2 json-c lzma m nghttp2
WANTLIB += pthread ssl unistring uv xml2 z
FLAVORS= geoip
FLAVOR?=
@ -33,16 +33,17 @@ MASTER_SITES0= ${MASTER_SITE_ISC:=bind9/$V/patches/}
MODULES= lang/python
# used for dnssec-checkds/dnssec-coverage, but don't want to force the run dep.
MODPY_RUNDEP= No
BUILD_DEPENDS= devel/py-ply${MODPY_FLAVOR}
BUILD_DEPENDS= textproc/py-sphinx${MODPY_FLAVOR}
LIB_DEPENDS= converters/libiconv \
devel/json-c \
devel/libidn2 \
devel/libuv \
textproc/libxml
textproc/libxml \
www/nghttp2
DEBUG_PACKAGES= ${BUILD_PACKAGES}
CONFIGURE_STYLE= autoconf
AUTOCONF_VERSION= 2.69
CONFIGURE_STYLE= gnu
USE_GMAKE= Yes
LIBTOOL_FLAGS= --tag=disable-static
CONFIGURE_ARGS= --enable-full-report \
--with-libtool \
@ -50,6 +51,7 @@ CONFIGURE_ARGS= --enable-full-report \
--without-lmdb \
--without-readline \
--without-cmocka \
--without-gssapi \
--with-python=${MODPY_BIN}
FAKE_FLAGS= sysconfdir=${PREFIX}/share/examples/bind9

View File

@ -1,2 +1,2 @@
SHA256 (bind-9.16.27.tar.xz) = kJAqrxBMgQGdddb4svfsQPzSSUBviUtE5KnGteCL9WY=
SIZE (bind-9.16.27.tar.xz) = 5084340
SHA256 (bind-9.18.1.tar.xz) = V8ev2HFpTWFctN77HBvW7QIzUJQ9dFhBTbjUk+9WBCc=
SIZE (bind-9.18.1.tar.xz) = 5059456

View File

@ -11,8 +11,8 @@ Index: bin/dig/dig.c
+#include <unistd.h>
#include <isc/app.h>
#include <isc/netaddr.h>
@@ -2641,6 +2642,15 @@ dig_setup(int argc, char **argv) {
#include <isc/attributes.h>
@@ -2881,6 +2882,15 @@ dig_setup(int argc, char **argv) {
ISC_LIST_INIT(server_list);
ISC_LIST_INIT(search_list);
@ -28,7 +28,7 @@ Index: bin/dig/dig.c
debug("dig_setup()");
/* setup dighost callbacks */
@@ -2672,6 +2682,21 @@ dig_query_setup(bool is_batchfile, bool config_only, i
@@ -2912,6 +2922,21 @@ dig_query_setup(bool is_batchfile, bool config_only, i
} else if (keysecret[0] != 0) {
setup_text_key();
}

View File

@ -11,8 +11,8 @@ Index: bin/dig/host.c
+#include <unistd.h>
#include <isc/app.h>
#include <isc/commandline.h>
@@ -903,6 +904,15 @@ main(int argc, char **argv) {
#include <isc/attributes.h>
@@ -906,6 +907,15 @@ main(int argc, char **argv) {
dighost_trying = trying;
dighost_shutdown = host_shutdown;
@ -28,7 +28,7 @@ Index: bin/dig/host.c
debug("main()");
progname = argv[0];
pre_parse_args(argc, argv);
@@ -916,6 +926,21 @@ main(int argc, char **argv) {
@@ -919,6 +929,21 @@ main(int argc, char **argv) {
} else if (keysecret[0] != 0) {
setup_text_key();
}

View File

@ -4,7 +4,7 @@ locale is needed for idn2.
Index: bin/dig/nslookup.c
--- bin/dig/nslookup.c.orig
+++ bin/dig/nslookup.c
@@ -1011,6 +1011,15 @@ main(int argc, char **argv) {
@@ -940,6 +940,15 @@ main(int argc, char **argv) {
result = isc_app_start();
check_result(result, "isc_app_start");
@ -20,7 +20,7 @@ Index: bin/dig/nslookup.c
setup_libs();
progname = argv[0];
@@ -1021,6 +1030,21 @@ main(int argc, char **argv) {
@@ -950,6 +959,21 @@ main(int argc, char **argv) {
} else if (keysecret[0] != 0) {
setup_text_key();
}

View File

@ -1,7 +1,7 @@
Index: bin/named/include/named/globals.h
--- bin/named/include/named/globals.h.orig
+++ bin/named/include/named/globals.h
@@ -135,7 +135,7 @@ EXTERN const char *named_g_defaultpidfile INIT(NAMED_L
@@ -139,7 +139,7 @@ EXTERN const char *named_g_defaultpidfile INIT(NAMED_L
"named.pid");
#endif /* if NAMED_RUN_PID_DIR */

View File

@ -1,15 +0,0 @@
"struct stat" is in stat.h not fcntl.h
https://gitlab.isc.org/isc-projects/bind9/-/issues/2905
Index: configure.ac
--- configure.ac.orig
+++ configure.ac
@@ -1856,7 +1856,7 @@ AC_DEFINE(NEED_OPTARG, 1, [Defined if extern char *opt
AC_MSG_CHECKING([for st_mtim.tv_nsec])
AC_COMPILE_IFELSE(
[AC_LANG_PROGRAM(
- [[#include <sys/fcntl.h>]],
+ [[#include <sys/stat.h>]],
[[struct stat s;
return(s.st_mtim.tv_nsec);
]])],

View File

@ -1,9 +1,9 @@
Patch to use pledge on OpenBSD.
Index: lib/isc/unix/net.c
--- lib/isc/unix/net.c.orig
+++ lib/isc/unix/net.c
@@ -223,6 +223,13 @@ isc_net_probeunix(void) {
Index: lib/isc/net.c
--- lib/isc/net.c.orig
+++ lib/isc/net.c
@@ -221,6 +221,13 @@ isc_net_probeunix(void) {
static void
try_ipv6only(void) {
@ -17,7 +17,7 @@ Index: lib/isc/unix/net.c
#ifdef IPV6_V6ONLY
int s, on;
char strbuf[ISC_STRERRORSIZE];
@@ -673,7 +680,7 @@ try_dscp_v6(void) {
@@ -671,7 +678,7 @@ try_dscp_v6(void) {
dscp_result |= ISC_NET_DSCPSETV6;
}

View File

@ -0,0 +1,42 @@
Patch to use pledge on OpenBSD.
Index: lib/isc/netmgr/netmgr.c
--- lib/isc/netmgr/netmgr.c.orig
+++ lib/isc/netmgr/netmgr.c
@@ -3157,7 +3157,8 @@ isc__nm_socket_disable_pmtud(uv_os_sock_t fd, sa_famil
* Disable the Path MTU Discovery on IP packets
*/
if (sa_family == AF_INET6) {
-#if defined(IPV6_DONTFRAG)
+/* disabled for pledge */
+#if !defined(__OpenBSD__) && defined(IPV6_DONTFRAG)
if (setsockopt_off(fd, IPPROTO_IPV6, IPV6_DONTFRAG) == -1) {
return (ISC_R_FAILURE);
} else {
@@ -3175,7 +3176,12 @@ isc__nm_socket_disable_pmtud(uv_os_sock_t fd, sa_famil
UNUSED(fd);
#endif
} else if (sa_family == AF_INET) {
-#if defined(IP_DONTFRAG)
+/*
+ OpenBSD doesn't have this yet but if we do get it sometime,
+ it will probably need the same pledge handling as IPV6_DONTFRAG
+ above
+ */
+#if !defined(__OpenBSD__) && defined(IP_DONTFRAG)
if (setsockopt_off(fd, IPPROTO_IP, IP_DONTFRAG) == -1) {
return (ISC_R_FAILURE);
} else {
@@ -3205,7 +3211,11 @@ isc__nm_socket_v6only(uv_os_sock_t fd, sa_family_t sa_
* Enable the IPv6-only option on IPv6 sockets
*/
if (sa_family == AF_INET6) {
-#if defined(IPV6_V6ONLY)
+/*
+ * pledge doesn't allow setting IPV6_V6ONLY, but that's ok,
+ * IPV6_V6ONLY is always enabled on OpenBSD
+ */
+#if !defined(__OpenBSD__) && defined(IPV6_V6ONLY)
if (setsockopt_on(fd, IPPROTO_IPV6, IPV6_V6ONLY) == -1) {
return (ISC_R_FAILURE);
} else {

View File

@ -1,48 +0,0 @@
Disable some socket options which pledge doesn't allow.
Index: lib/isc/unix/socket.c
--- lib/isc/unix/socket.c.orig
+++ lib/isc/unix/socket.c
@@ -2106,10 +2106,12 @@ set_ip_disable_pmtud(isc_socket_t *sock) {
* Disable Path MTU Discover on IP packets
*/
if (sock->pf == AF_INET6) {
+#if !defined(__OpenBSD__) /* pledge doesn't allow "don't fragment" sockopts */
#if defined(IPV6_DONTFRAG)
(void)setsockopt(sock->fd, IPPROTO_IPV6, IPV6_DONTFRAG,
&(int){ 0 }, sizeof(int));
#endif
+#endif
#if defined(IPV6_MTU_DISCOVER) && defined(IP_PMTUDISC_OMIT)
(void)setsockopt(sock->fd, IPPROTO_IPV6, IPV6_MTU_DISCOVER,
&(int){ IP_PMTUDISC_OMIT }, sizeof(int));
@@ -2386,6 +2388,7 @@ again:
}
#endif /* if defined(SO_SNDBUF) */
}
+#if !defined(__OpenBSD__) /* pledge doesn't allow "receive ToS" sockopts */
#ifdef IPV6_RECVTCLASS
if ((sock->pf == AF_INET6) &&
(setsockopt(sock->fd, IPPROTO_IPV6, IPV6_RECVTCLASS, (void *)&on,
@@ -2410,6 +2413,7 @@ again:
sock->fd, strbuf);
}
#endif /* ifdef IP_RECVTOS */
+#endif
#endif /* defined(USE_CMSG) || defined(SET_RCVBUF) || defined(SET_SNDBUF) */
set_ip_disable_pmtud(sock);
@@ -5092,6 +5096,13 @@ isc_socket_gettype(isc_socket_t *sock) {
void
isc_socket_ipv6only(isc_socket_t *sock, bool yes) {
+#ifdef __OpenBSD__
+/*
+ * pledge doesn't allow setting IPV6_V6ONLY, but that's ok,
+ * IPV6_V6ONLY is always enabled on OpenBSD;
+ */
+#undef IPV6_V6ONLY
+#endif
#if defined(IPV6_V6ONLY)
int onoff = yes ? 1 : 0;
#else /* if defined(IPV6_V6ONLY) */

View File

@ -7,18 +7,31 @@
@bin bin/arpaname
@bin bin/delv
@bin bin/dig
@bin bin/dnssec-cds
@bin bin/dnssec-dsfromkey
@bin bin/dnssec-importkey
@bin bin/dnssec-keyfromlabel
@bin bin/dnssec-keygen
@bin bin/dnssec-revoke
@bin bin/dnssec-settime
@bin bin/dnssec-signzone
@bin bin/dnssec-verify
bin/edig
bin/ehost
bin/enslookup
@bin bin/host
@bin bin/mdig
@bin bin/named-checkconf
@bin bin/named-checkzone
@bin bin/named-compilezone
@bin bin/named-journalprint
@bin bin/named-rrchecker
@bin bin/nsec3hash
@bin bin/nslookup
@bin bin/nsupdate
include/bind9/
include/bind9/check.h
include/bind9/getaddresses.h
include/bind9/version.h
include/dns/
include/dns/acl.h
include/dns/adb.h
@ -34,7 +47,6 @@ include/dns/clientinfo.h
include/dns/compress.h
include/dns/db.h
include/dns/dbiterator.h
include/dns/dbtable.h
include/dns/diff.h
include/dns/dispatch.h
include/dns/dlz.h
@ -46,7 +58,6 @@ include/dns/dnstap.h
include/dns/ds.h
include/dns/dsdigest.h
include/dns/dyndb.h
include/dns/ecdb.h
include/dns/ecs.h
include/dns/edns.h
include/dns/enumclass.h
@ -64,9 +75,7 @@ include/dns/keyflags.h
include/dns/keymgr.h
include/dns/keytable.h
include/dns/keyvalues.h
include/dns/lib.h
include/dns/librpz.h
include/dns/lmdb.h
include/dns/log.h
include/dns/lookup.h
include/dns/master.h
@ -80,7 +89,6 @@ include/dns/nta.h
include/dns/opcode.h
include/dns/order.h
include/dns/peer.h
include/dns/portlist.h
include/dns/private.h
include/dns/rbt.h
include/dns/rcode.h
@ -106,17 +114,15 @@ include/dns/secproto.h
include/dns/soa.h
include/dns/ssu.h
include/dns/stats.h
include/dns/tcpmsg.h
include/dns/time.h
include/dns/timer.h
include/dns/tkey.h
include/dns/transport.h
include/dns/tsec.h
include/dns/tsig.h
include/dns/ttl.h
include/dns/types.h
include/dns/update.h
include/dns/validator.h
include/dns/version.h
include/dns/view.h
include/dns/xfrin.h
include/dns/zone.h
@ -126,15 +132,8 @@ include/dns/zt.h
include/dst/
include/dst/dst.h
include/dst/gssapi.h
include/dst/result.h
include/irs/
include/irs/context.h
include/irs/dnsconf.h
include/irs/netdb.h
include/irs/platform.h
include/irs/resconf.h
include/irs/types.h
include/irs/version.h
include/isc/
include/isc/aes.h
include/isc/align.h
@ -142,13 +141,13 @@ include/isc/app.h
include/isc/assertions.h
include/isc/astack.h
include/isc/atomic.h
include/isc/attributes.h
include/isc/backtrace.h
include/isc/barrier.h
include/isc/base32.h
include/isc/base64.h
include/isc/bind9.h
include/isc/buffer.h
include/isc/bufferlist.h
include/isc/cmocka.h
include/isc/commandline.h
include/isc/condition.h
@ -165,6 +164,7 @@ include/isc/file.h
include/isc/formatcheck.h
include/isc/fsaccess.h
include/isc/fuzz.h
include/isc/glob.h
include/isc/hash.h
include/isc/heap.h
include/isc/hex.h
@ -176,9 +176,6 @@ include/isc/interfaceiter.h
include/isc/iterated_hash.h
include/isc/lang.h
include/isc/lex.h
include/isc/lfsr.h
include/isc/lib.h
include/isc/likely.h
include/isc/list.h
include/isc/log.h
include/isc/magic.h
@ -187,7 +184,6 @@ include/isc/md.h
include/isc/mem.h
include/isc/meminfo.h
include/isc/mutex.h
include/isc/mutexatomic.h
include/isc/mutexblock.h
include/isc/net.h
include/isc/netaddr.h
@ -199,7 +195,6 @@ include/isc/offset.h
include/isc/once.h
include/isc/os.h
include/isc/parseint.h
include/isc/platform.h
include/isc/pool.h
include/isc/portset.h
include/isc/print.h
@ -213,13 +208,11 @@ include/isc/regex.h
include/isc/region.h
include/isc/resource.h
include/isc/result.h
include/isc/resultclass.h
include/isc/rwlock.h
include/isc/safe.h
include/isc/serial.h
include/isc/siphash.h
include/isc/sockaddr.h
include/isc/socket.h
include/isc/stat.h
include/isc/stats.h
include/isc/stdatomic.h
@ -234,39 +227,35 @@ include/isc/taskpool.h
include/isc/thread.h
include/isc/time.h
include/isc/timer.h
include/isc/tls.h
include/isc/tm.h
include/isc/types.h
include/isc/url.h
include/isc/utf8.h
include/isc/util.h
include/isc/version.h
include/isccc/
include/isccc/alist.h
include/isccc/base64.h
include/isccc/cc.h
include/isccc/ccmsg.h
include/isccc/events.h
include/isccc/result.h
include/isccc/sexpr.h
include/isccc/symtab.h
include/isccc/symtype.h
include/isccc/types.h
include/isccc/util.h
include/isccc/version.h
include/isccfg/
include/isccfg/aclconf.h
include/isccfg/cfg.h
include/isccfg/dnsconf.h
include/isccfg/grammar.h
include/isccfg/kaspconf.h
include/isccfg/log.h
include/isccfg/namedconf.h
include/isccfg/version.h
include/ns/
include/ns/client.h
include/ns/events.h
include/ns/hooks.h
include/ns/interfacemgr.h
include/ns/lib.h
include/ns/listenlist.h
include/ns/log.h
include/ns/notify.h
@ -276,16 +265,12 @@ include/ns/sortlist.h
include/ns/stats.h
include/ns/types.h
include/ns/update.h
include/ns/version.h
include/ns/xfrout.h
include/pk11/
include/pk11/constants.h
include/pk11/internal.h
include/pk11/pk11.h
include/pk11/result.h
include/pk11/site.h
include/pkcs11/
include/pkcs11/pkcs11.h
lib/bind/
lib/bind/filter-a.la
@so lib/bind/filter-a.so
lib/bind/filter-aaaa.la
@so lib/bind/filter-aaaa.so
@so lib/libbind9-${V}.so
lib/libbind9.la
@so lib/libbind9.so
@ -307,99 +292,45 @@ lib/libisccfg.la
@so lib/libns-${V}.so
lib/libns.la
@so lib/libns.so
lib/named/
@so lib/named/filter-aaaa.so
lib/python${MODPY_VERSION}/
lib/python${MODPY_VERSION}/site-packages/
lib/python${MODPY_VERSION}/site-packages/isc/
lib/python${MODPY_VERSION}/site-packages/isc-2.0-py${MODPY_VERSION}.egg-info
lib/python${MODPY_VERSION}/site-packages/isc/__init__.py
${MODPY_COMMENT}lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}/
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}__init__.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}checkds.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}coverage.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}dnskey.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}eventlist.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}keydict.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}keyevent.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}keymgr.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}keyseries.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}keyzone.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}parsetab.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}policy.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}rndc.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/${MODPY_PYCACHE}utils.${MODPY_PYC_MAGIC_TAG}pyc
lib/python${MODPY_VERSION}/site-packages/isc/checkds.py
lib/python${MODPY_VERSION}/site-packages/isc/coverage.py
lib/python${MODPY_VERSION}/site-packages/isc/dnskey.py
lib/python${MODPY_VERSION}/site-packages/isc/eventlist.py
lib/python${MODPY_VERSION}/site-packages/isc/keydict.py
lib/python${MODPY_VERSION}/site-packages/isc/keyevent.py
lib/python${MODPY_VERSION}/site-packages/isc/keymgr.py
lib/python${MODPY_VERSION}/site-packages/isc/keyseries.py
lib/python${MODPY_VERSION}/site-packages/isc/keyzone.py
lib/python${MODPY_VERSION}/site-packages/isc/parsetab.py
lib/python${MODPY_VERSION}/site-packages/isc/policy.py
lib/python${MODPY_VERSION}/site-packages/isc/rndc.py
lib/python${MODPY_VERSION}/site-packages/isc/utils.py
@man man/man1/arpaname.1
@man man/man1/delv.1
@man man/man1/dig.1
@man man/man1/dnssec-cds.1
@man man/man1/dnssec-dsfromkey.1
@man man/man1/dnssec-importkey.1
@man man/man1/dnssec-keyfromlabel.1
@man man/man1/dnssec-keygen.1
@man man/man1/dnssec-revoke.1
@man man/man1/dnssec-settime.1
@man man/man1/dnssec-signzone.1
@man man/man1/dnssec-verify.1
@man man/man1/edig.1
@man man/man1/ehost.1
@man man/man1/enslookup.1
@man man/man1/host.1
@man man/man1/mdig.1
@man man/man1/named-checkconf.1
@man man/man1/named-checkzone.1
@man man/man1/named-compilezone.1
@man man/man1/named-journalprint.1
@man man/man1/named-rrchecker.1
@man man/man1/nsec3hash.1
@man man/man1/nslookup.1
@man man/man1/nsupdate.1
@man man/man5/named.conf.5
@man man/man5/rndc.conf.5
@man man/man8/ddns-confgen.8
@man man/man8/dnssec-cds.8
@man man/man8/dnssec-checkds.8
@man man/man8/dnssec-coverage.8
@man man/man8/dnssec-dsfromkey.8
@man man/man8/dnssec-importkey.8
@man man/man8/dnssec-keyfromlabel.8
@man man/man8/dnssec-keygen.8
@man man/man8/dnssec-keymgr.8
@man man/man8/dnssec-revoke.8
@man man/man8/dnssec-settime.8
@man man/man8/dnssec-signzone.8
@man man/man8/dnssec-verify.8
@man man/man8/filter-a.8
@man man/man8/filter-aaaa.8
@man man/man8/named-checkconf.8
@man man/man8/named-checkzone.8
@man man/man8/named-compilezone.8
@man man/man8/named-journalprint.8
@man man/man8/named.8
@man man/man8/nsec3hash.8
@man man/man8/rndc-confgen.8
@man man/man8/rndc.8
@man man/man8/tsig-keygen.8
@bin sbin/ddns-confgen
@bin sbin/dnssec-cds
sbin/dnssec-checkds
sbin/dnssec-coverage
@bin sbin/dnssec-dsfromkey
@bin sbin/dnssec-importkey
@bin sbin/dnssec-keyfromlabel
@bin sbin/dnssec-keygen
sbin/dnssec-keymgr
@bin sbin/dnssec-revoke
@bin sbin/dnssec-settime
@bin sbin/dnssec-signzone
@bin sbin/dnssec-verify
@bin sbin/named
@bin sbin/named-checkconf
@bin sbin/named-checkzone
sbin/named-compilezone
@bin sbin/named-journalprint
@bin sbin/nsec3hash
@bin sbin/rndc
@bin sbin/rndc-confgen
sbin/tsig-keygen
@bin sbin/tsig-keygen
@sample ${LOCALSTATEDIR}/named/
@mode 750
@group _bind