mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 06:25:31 +00:00
1879. [func] Added framework for handling multiple EDNS versions.
1878. [func] dig can now specify the EDNS version when making a query.
This commit is contained in:
@@ -15,7 +15,7 @@
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
/* $Id: dig.c,v 1.203 2005/04/27 04:55:44 sra Exp $ */
|
||||
/* $Id: dig.c,v 1.204 2005/06/07 00:15:58 marka Exp $ */
|
||||
|
||||
/*! \file */
|
||||
|
||||
@@ -192,6 +192,7 @@ help(void) {
|
||||
" +domain=### (Set default domainname)\n"
|
||||
" +bufsize=### (Set EDNS0 Max UDP packet size)\n"
|
||||
" +ndots=### (Set NDOTS value)\n"
|
||||
" +edns=### (Set EDNS version)\n"
|
||||
" +[no]search (Set whether to use searchlist)\n"
|
||||
" +[no]defname (Ditto)\n"
|
||||
" +[no]recurse (Recursive mode)\n"
|
||||
@@ -854,6 +855,8 @@ plus_option(char *option, isc_boolean_t is_batchfile,
|
||||
break;
|
||||
case 'n': /* dnssec */
|
||||
FULLCHECK("dnssec");
|
||||
if (state && lookup->edns == -1)
|
||||
lookup->edns = 0;
|
||||
lookup->dnssec = state;
|
||||
break;
|
||||
case 'o': /* domain */
|
||||
@@ -869,6 +872,16 @@ plus_option(char *option, isc_boolean_t is_batchfile,
|
||||
goto invalid_option;
|
||||
}
|
||||
break;
|
||||
case 'e':
|
||||
FULLCHECK("edns");
|
||||
if (!state) {
|
||||
lookup->edns = -1;
|
||||
break;
|
||||
}
|
||||
if (value == NULL)
|
||||
goto need_value;
|
||||
lookup->edns = (isc_int16_t) parse_uint(value, "edns", 255);
|
||||
break;
|
||||
case 'f': /* fail */
|
||||
FULLCHECK("fail");
|
||||
lookup->servfail_stops = state;
|
||||
|
Reference in New Issue
Block a user