bind9/lib/ns
Matthijs Mekking 86a80e723f Consider non-stale data when in serve-stale mode
With 'stale-answer-enable yes;' and 'stale-answer-client-timeout off;',
consider the following situation:

A CNAME record and its target record are in the cache, then the CNAME
record expires, but the target record is still valid.

When a new query for the CNAME record arrives, and the query fails,
the stale record is used, and then the query "restarts" to follow
the CNAME target. The problem is that the query's multiple stale
options (like DNS_DBFIND_STALEOK) are not reset, so 'query_lookup()'
treats the restarted query as a lookup following a failed lookup,
and returns a SERVFAIL answer when there is no stale data found in the
cache, even if there is valid non-stale data there available.

With this change, query_lookup() now considers non-stale data in the
cache in the first place, and returns it if it is available.
2022-12-06 13:26:53 +00:00
..
include remove unused 'nupdates' field from client 2022-11-23 23:44:10 +00:00
client.c Remove the unused cache cleaning mechanism from dns_cache API 2022-11-29 13:48:33 -08:00
hooks.c Update sources to Clang 15 formatting 2022-11-29 08:54:34 +01:00
interfacemgr.c Update sources to Clang 15 formatting 2022-11-29 08:54:34 +01:00
listenlist.c Update sources to Clang 15 formatting 2022-11-29 08:54:34 +01:00
log.c Update the copyright information in all files in the repository 2022-01-11 09:05:02 +01:00
Makefile.am Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00
notify.c Update the copyright information in all files in the repository 2022-01-11 09:05:02 +01:00
query.c Consider non-stale data when in serve-stale mode 2022-12-06 13:26:53 +00:00
server.c Use designated initializers instead of memset()/MEM_ZERO for structs 2022-10-05 16:44:05 +02:00
sortlist.c De-duplicate __FILE__, __LINE__ 2022-10-17 11:58:26 +01:00
stats.c Update the copyright information in all files in the repository 2022-01-11 09:05:02 +01:00
tests Move all the unit tests to /tests/<libname>/ 2022-05-28 14:53:02 -07:00
update.c Update sources to Clang 15 formatting 2022-11-29 08:54:34 +01:00
xfrout.c Compress zone transfers properly 2022-11-30 12:16:09 +00:00