bind9/bin/tests/system/staticstub
Evan Hunt 3704cf42eb Don't use dns_db_findzonecut() in query_addbestns()
Previously, when answering from the cache, and when minimal-responses
was not set, we added the best known zone cut to the authority section
of the response message, using dns_db_findzonecut() to look it up in
the DNS cache.  Since the DNS cache will no longer be used to store
parent-side NS RRsets, it will now be possible for an ancestor node
to be used as the zone cut, leading to the wrong NS record being
included.

There are various ways we could correct this:

1. Use dns_deleg_lookup() instead of dns_db_findzonecut() to find the
   zone cut. But currently, the deleg database stores only the server
   addresses for the delegation, not the full NS RRset; this would need
   to be changed.
2. Look up <name>/NS whenever we cache a referral; that way we'll get
   the child-side NS RRset and cache that, and we can retrieve it when
   building the response.

But the solution chosen here is simply not to look up the NS record
when answering from the cache, effectively making "minimal-responses
yes;" mandatory for queries answered from the cache.

System tests have been updated as needed, so they no longer expect
NS RRsets in the authority section of recursive responses.
2026-03-30 20:41:13 +02:00
..
conf Update the copyright information in all files in the repository 2022-01-11 09:05:02 +01:00
ns1 Use jinja2 templates in staticstub test 2025-12-09 14:23:17 +01:00
ns2 Use jinja2 templates in staticstub test 2025-12-09 14:23:17 +01:00
ns3 Use jinja2 templates in staticstub test 2025-12-09 14:23:17 +01:00
ns4 Use jinja2 templates in staticstub test 2025-12-09 14:23:17 +01:00
knowngood.dig.out.rec 3593. [func] Update EDNS processing to better track remote server 2013-06-12 11:31:30 +10:00
setup.sh Use jinja2 templates in staticstub test 2025-12-09 14:23:17 +01:00
tests.sh Don't use dns_db_findzonecut() in query_addbestns() 2026-03-30 20:41:13 +02:00
tests_sh_staticstub.py Replace clean.sh files with extra_artifacts mark 2024-11-08 10:54:24 +01:00