mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-29 13:38:26 +00:00
3992. [func] DiG can now send queries without questions
(dig +header-only). [RT #37599]
This commit is contained in:
parent
00fb0253c9
commit
f274cbeaed
3
CHANGES
3
CHANGES
@ -1,3 +1,6 @@
|
|||||||
|
3992. [func] DiG can now send queries without questions
|
||||||
|
(dig +header-only). [RT #37599]
|
||||||
|
|
||||||
3991. [func] Add the ability to buffer logging output by specifying
|
3991. [func] Add the ability to buffer logging output by specifying
|
||||||
"buffered yes;" when defining a channel. [RT #26561]
|
"buffered yes;" when defining a channel. [RT #26561]
|
||||||
|
|
||||||
|
@ -230,6 +230,7 @@ help(void) {
|
|||||||
" +[no]dnssec (Request DNSSEC records)\n"
|
" +[no]dnssec (Request DNSSEC records)\n"
|
||||||
" +[no]expire (Request time to expire)\n"
|
" +[no]expire (Request time to expire)\n"
|
||||||
" +[no]nsid (Request Name Server ID)\n"
|
" +[no]nsid (Request Name Server ID)\n"
|
||||||
|
" +[no]header-only (Send query without a question section)\n"
|
||||||
#ifdef ISC_PLATFORM_USESIT
|
#ifdef ISC_PLATFORM_USESIT
|
||||||
" +[no]sit (Request a Source Identity Token)\n"
|
" +[no]sit (Request a Source Identity Token)\n"
|
||||||
#endif
|
#endif
|
||||||
@ -1017,6 +1018,10 @@ plus_option(char *option, isc_boolean_t is_batchfile,
|
|||||||
FULLCHECK("fail");
|
FULLCHECK("fail");
|
||||||
lookup->servfail_stops = state;
|
lookup->servfail_stops = state;
|
||||||
break;
|
break;
|
||||||
|
case 'h':
|
||||||
|
FULLCHECK("header-only");
|
||||||
|
lookup->header_only = state;
|
||||||
|
break;
|
||||||
case 'i':
|
case 'i':
|
||||||
switch (cmd[1]) {
|
switch (cmd[1]) {
|
||||||
case 'd': /* identify */
|
case 'd': /* identify */
|
||||||
|
@ -622,6 +622,17 @@
|
|||||||
</listitem>
|
</listitem>
|
||||||
</varlistentry>
|
</varlistentry>
|
||||||
|
|
||||||
|
<varlistentry>
|
||||||
|
<term><option>+[no]header-only</option></term>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
Send a query with a DNS header without a question section.
|
||||||
|
The default is to add a question section. The query type
|
||||||
|
and query name are ignored when this is set.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
|
</varlistentry>
|
||||||
|
|
||||||
<varlistentry>
|
<varlistentry>
|
||||||
<term><option>+[no]identify</option></term>
|
<term><option>+[no]identify</option></term>
|
||||||
<listitem>
|
<listitem>
|
||||||
|
@ -786,6 +786,7 @@ make_empty_lookup(void) {
|
|||||||
looknew->ednsflags = 0;
|
looknew->ednsflags = 0;
|
||||||
looknew->expire = ISC_FALSE;
|
looknew->expire = ISC_FALSE;
|
||||||
looknew->nsid = ISC_FALSE;
|
looknew->nsid = ISC_FALSE;
|
||||||
|
looknew->header_only = ISC_FALSE;
|
||||||
#ifdef ISC_PLATFORM_USESIT
|
#ifdef ISC_PLATFORM_USESIT
|
||||||
looknew->sit = ISC_FALSE;
|
looknew->sit = ISC_FALSE;
|
||||||
#endif
|
#endif
|
||||||
@ -881,6 +882,7 @@ clone_lookup(dig_lookup_t *lookold, isc_boolean_t servers) {
|
|||||||
looknew->ednsflags = lookold->ednsflags;
|
looknew->ednsflags = lookold->ednsflags;
|
||||||
looknew->expire = lookold->expire;
|
looknew->expire = lookold->expire;
|
||||||
looknew->nsid = lookold->nsid;
|
looknew->nsid = lookold->nsid;
|
||||||
|
looknew->header_only = lookold->header_only;
|
||||||
#ifdef ISC_PLATFORM_USESIT
|
#ifdef ISC_PLATFORM_USESIT
|
||||||
looknew->sit = lookold->sit;
|
looknew->sit = lookold->sit;
|
||||||
looknew->sitvalue = lookold->sitvalue;
|
looknew->sitvalue = lookold->sitvalue;
|
||||||
@ -2431,8 +2433,9 @@ setup_lookup(dig_lookup_t *lookup) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
add_question(lookup->sendmsg, lookup->name, lookup->rdclass,
|
if (!lookup->header_only)
|
||||||
lookup->rdtype);
|
add_question(lookup->sendmsg, lookup->name, lookup->rdclass,
|
||||||
|
lookup->rdtype);
|
||||||
|
|
||||||
/* add_soa */
|
/* add_soa */
|
||||||
if (lookup->rdtype == dns_rdatatype_ixfr)
|
if (lookup->rdtype == dns_rdatatype_ixfr)
|
||||||
|
@ -135,7 +135,8 @@ struct dig_lookup {
|
|||||||
#ifdef ISC_PLATFORM_USESIT
|
#ifdef ISC_PLATFORM_USESIT
|
||||||
sit,
|
sit,
|
||||||
#endif
|
#endif
|
||||||
nsid; /*% Name Server ID (RFC 5001) */
|
nsid, /*% Name Server ID (RFC 5001) */
|
||||||
|
header_only;
|
||||||
#ifdef DIG_SIGCHASE
|
#ifdef DIG_SIGCHASE
|
||||||
isc_boolean_t sigchase;
|
isc_boolean_t sigchase;
|
||||||
#if DIG_SIGCHASE_TD
|
#if DIG_SIGCHASE_TD
|
||||||
|
@ -127,6 +127,12 @@
|
|||||||
yet-to-be-defined EDNS flags in DNS requests.
|
yet-to-be-defined EDNS flags in DNS requests.
|
||||||
</para>
|
</para>
|
||||||
</listitem>
|
</listitem>
|
||||||
|
<listitem>
|
||||||
|
<para>
|
||||||
|
<command>dig +header-only</command> can now be used to send
|
||||||
|
queries without a question section.
|
||||||
|
</para>
|
||||||
|
</listitem>
|
||||||
<listitem>
|
<listitem>
|
||||||
<para>
|
<para>
|
||||||
<command>dig +ttlunits</command> causes <command>dig</command>
|
<command>dig +ttlunits</command> causes <command>dig</command>
|
||||||
|
Loading…
x
Reference in New Issue
Block a user