]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Allow empty APL records
authorAram Sargsyan <aram@isc.org>
Mon, 23 Mar 2026 15:15:18 +0000 (15:15 +0000)
committerArаm Sаrgsyаn (GitLab job 7101883) <aram@isc.org>
Fri, 27 Mar 2026 12:38:00 +0000 (12:38 +0000)
Allow empty APL records because RFC 3123 (Section 4) says "zero or
more items". This fixes processing of a catalog zone ACL (which is
based on APL records) when the zone contains an empty APL record or
when a zone update arrives which creates an empty APL record.

(cherry picked from commit 35b8af229e82291fd635225ac45f853e7190f8b7)

lib/dns/rdata/in_1/apl_42.c

index 67c021062b6c40e68fdab4309a655b8a0c72afdb..ee33fa5c5735738742cec875e7408e7aa87b8f80 100644 (file)
@@ -327,7 +327,7 @@ dns_rdata_apl_first(dns_rdata_in_apl_t *apl) {
        /*
         * If no APL return ISC_R_NOMORE.
         */
-       if (apl->apl == NULL) {
+       if (apl->apl == NULL || apl->apl_len == 0) {
                return ISC_R_NOMORE;
        }