mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 14:35:26 +00:00
971. [func] 'try-edns' can be use to disable edns on all queries.
This commit is contained in:
@@ -15,7 +15,7 @@
|
||||
* WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: adb.c,v 1.181 2001/08/08 22:54:36 gson Exp $ */
|
||||
/* $Id: adb.c,v 1.182 2001/08/30 05:52:14 marka Exp $ */
|
||||
|
||||
/*
|
||||
* Implementation notes
|
||||
@@ -1593,6 +1593,7 @@ a6missing(dns_a6context_t *a6ctx, dns_name_t *a6name) {
|
||||
dns_adb_t *adb;
|
||||
dns_adbfetch6_t *fetch;
|
||||
isc_result_t result;
|
||||
unsigned int options = 0;
|
||||
|
||||
name = a6ctx->arg;
|
||||
INSIST(DNS_ADBNAME_VALID(name));
|
||||
@@ -1605,9 +1606,11 @@ a6missing(dns_a6context_t *a6ctx, dns_name_t *a6name) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!adb->view->tryedns)
|
||||
options |= DNS_FETCHOPT_NOEDNS0;
|
||||
result = dns_resolver_createfetch(adb->view->resolver, a6name,
|
||||
dns_rdatatype_a6,
|
||||
NULL, NULL, NULL, 0,
|
||||
NULL, NULL, NULL, options,
|
||||
adb->task, fetch_callback_a6,
|
||||
name, &fetch->rdataset, NULL,
|
||||
&fetch->fetch);
|
||||
@@ -3748,6 +3751,8 @@ fetch_name_v4(dns_adbname_t *adbname, isc_boolean_t start_at_root) {
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
if (!adb->view->tryedns)
|
||||
options |= DNS_FETCHOPT_NOEDNS0;
|
||||
result = dns_resolver_createfetch(adb->view->resolver, &adbname->name,
|
||||
dns_rdatatype_a,
|
||||
name, nameservers, NULL, options,
|
||||
@@ -3775,6 +3780,7 @@ fetch_name_aaaa(dns_adbname_t *adbname) {
|
||||
isc_result_t result;
|
||||
dns_adbfetch_t *fetch;
|
||||
dns_adb_t *adb;
|
||||
unsigned int options = 0;
|
||||
|
||||
INSIST(DNS_ADBNAME_VALID(adbname));
|
||||
adb = adbname->adb;
|
||||
@@ -3790,9 +3796,11 @@ fetch_name_aaaa(dns_adbname_t *adbname) {
|
||||
goto cleanup;
|
||||
}
|
||||
|
||||
if (!adb->view->tryedns)
|
||||
options |= DNS_FETCHOPT_NOEDNS0;
|
||||
result = dns_resolver_createfetch(adb->view->resolver, &adbname->name,
|
||||
dns_rdatatype_aaaa,
|
||||
NULL, NULL, NULL, 0,
|
||||
NULL, NULL, NULL, options,
|
||||
adb->task, fetch_callback,
|
||||
adbname, &fetch->rdataset, NULL,
|
||||
&fetch->fetch);
|
||||
@@ -3851,6 +3859,8 @@ fetch_name_a6(dns_adbname_t *adbname, isc_boolean_t start_at_root) {
|
||||
}
|
||||
fetch->flags |= FETCH_FIRST_A6;
|
||||
|
||||
if (!adb->view->tryedns)
|
||||
options |= DNS_FETCHOPT_NOEDNS0;
|
||||
result = dns_resolver_createfetch(adb->view->resolver, &adbname->name,
|
||||
dns_rdatatype_a6,
|
||||
name, nameservers, NULL, options,
|
||||
|
Reference in New Issue
Block a user