]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
new: test: Handle alias records in zone files loaded by AsyncDnsServer
authorMichał Kępień <michal@isc.org>
Fri, 30 May 2025 16:18:07 +0000 (16:18 +0000)
committerMichał Kępień <michal@isc.org>
Fri, 30 May 2025 16:18:07 +0000 (16:18 +0000)
dnspython does not treat CNAME records in zone files in any special way;
they are just RRsets belonging to zone nodes.  Process CNAMEs when
preparing zone-based responses just like a normal authoritative DNS
server would.

Adding proper DNAME support to AsyncDnsServer would add complexity to
its code for little gain: DNAME use in custom system test servers is
limited to crafting responses that attempt to trigger bugs in named.

This fact will not be obvious to AsyncDnsServer users as it
automatically loads all zone files it finds and handles CNAME records
like a normal authoritative DNS server would.

Therefore, to prevent surprises:

- raise an exception whenever DNAME records are found in any of the
zone files loaded by AsyncDnsServer,

- add a new optional argument to the AsyncDnsServer constructor that
enables suppressing this new behavior, enabling zones with DNAME
records to be loaded anyway.

This enables response handlers to use the DNAME records present in zone
files in arbitrary ways without complicating the "base" code.

Merge branch 'michal/asyncserver-alias-records' into 'main'

See merge request isc-projects/bind9!10409


Trivial merge