mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 22:45:39 +00:00
Improve a corner source of SERVFAILs [RT #19632]
This commit is contained in:
2
CHANGES
2
CHANGES
@@ -1,3 +1,5 @@
|
||||
2593. [bug] Improve a corner source of SERVFAILs [RT #19632]
|
||||
|
||||
2592. [bug] Treat "any" as a type in nsupdate. [RT #19455]
|
||||
|
||||
2591. [bug] named could die when processing a update in
|
||||
|
@@ -15,7 +15,7 @@
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: query.c,v 1.322 2009/03/13 01:35:18 marka Exp $ */
|
||||
/* $Id: query.c,v 1.323 2009/04/30 11:45:10 fdupont Exp $ */
|
||||
|
||||
/*! \file */
|
||||
|
||||
@@ -3321,6 +3321,14 @@ do { \
|
||||
line = __LINE__; \
|
||||
} while (0)
|
||||
|
||||
#define RECURSE_ERROR(r) \
|
||||
do { \
|
||||
if ((r) == DNS_R_DUPLICATE || (r) == DNS_R_DROP) \
|
||||
QUERY_ERROR(r); \
|
||||
else \
|
||||
QUERY_ERROR(DNS_R_SERVFAIL); \
|
||||
} while (0)
|
||||
|
||||
/*
|
||||
* Extract a network address from the RDATA of an A or AAAA
|
||||
* record.
|
||||
@@ -4003,14 +4011,8 @@ query_find(ns_client_t *client, dns_fetchevent_t *event, dns_rdatatype_t qtype)
|
||||
if (result == ISC_R_SUCCESS)
|
||||
client->query.attributes |=
|
||||
NS_QUERYATTR_RECURSING;
|
||||
else if (result == DNS_R_DUPLICATE ||
|
||||
result == DNS_R_DROP) {
|
||||
/* Duplicate query. */
|
||||
QUERY_ERROR(result);
|
||||
} else {
|
||||
/* Unable to recurse. */
|
||||
QUERY_ERROR(DNS_R_SERVFAIL);
|
||||
}
|
||||
else
|
||||
RECURSE_ERROR(result);
|
||||
goto cleanup;
|
||||
} else {
|
||||
/* Unable to give root server referral. */
|
||||
@@ -4189,11 +4191,8 @@ query_find(ns_client_t *client, dns_fetchevent_t *event, dns_rdatatype_t qtype)
|
||||
if (result == ISC_R_SUCCESS)
|
||||
client->query.attributes |=
|
||||
NS_QUERYATTR_RECURSING;
|
||||
else if (result == DNS_R_DUPLICATE ||
|
||||
result == DNS_R_DROP)
|
||||
QUERY_ERROR(result);
|
||||
else
|
||||
QUERY_ERROR(DNS_R_SERVFAIL);
|
||||
RECURSE_ERROR(result);
|
||||
} else {
|
||||
dns_fixedname_t fixed;
|
||||
|
||||
@@ -4733,7 +4732,8 @@ query_find(ns_client_t *client, dns_fetchevent_t *event, dns_rdatatype_t qtype)
|
||||
client->query.attributes |=
|
||||
NS_QUERYATTR_RECURSING;
|
||||
else
|
||||
QUERY_ERROR(DNS_R_SERVFAIL); }
|
||||
RECURSE_ERROR(result);
|
||||
}
|
||||
goto addauth;
|
||||
}
|
||||
/*
|
||||
|
Reference in New Issue
Block a user