host.c revision 16d00613cfd499ce96fcc3ad00275cb50ec5de74
70e5a7403f0e0a3bd292b8287c5fed5772c15270Automatic Updater * Copyright (C) 2000 Internet Software Consortium.
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer * Permission to use, copy, modify, and distribute this software for any
ec5347e2c775f027573ce5648b910361aa926c01Automatic Updater * purpose with or without fee is hereby granted, provided that the above
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer * copyright notice and this permission notice appear in all copies.
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer * THE SOFTWARE IS PROVIDED "AS IS" AND INTERNET SOFTWARE CONSORTIUM DISCLAIMS
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews * ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews * OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL INTERNET SOFTWARE
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews * CONSORTIUM BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews * DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews * PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS
1fa26403d7679235a30fbf6289f68fed5872df30Mark Andrews * ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrenceextern ISC_LIST(dig_searchlist_t) search_list;
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrenceextern unsigned int timeout;
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencestatic char *opcodetext[] = {
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence "RESERVED10",
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence "RESERVED11",
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence "RESERVED12",
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence "RESERVED13",
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrence "RESERVED14",
487e6abc16c1b2958d371b0d4e808953646b520aDavid Lawrencestatic char *rcodetext[] = {
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer "RESERVED11",
6ceca14e5ea7972a9ba8bc1dca0de1f63f669cfdDanny Mayer "RESERVED12",
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews "RESERVED13",
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews "RESERVED14",
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrews "RESERVED15",
ecffc3aae3e72c5c65b1911ec3f4e1d180dc4bbcMark Andrewsstatic char *rtypetext[] = {
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer"Usage: host [-aCdlrTwv] [-c class] [-N ndots] [-t type] [-W time]\n"
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer" [-R number] hostname [server]\n"
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer" -a is equivalent to -v -t *\n"
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer" -c specifies query class for non-IN data\n"
d3243476c280d3a98cadbfd6343437fa2b29356bDanny Mayer" -C compares SOA records on authorative nameservers\n"
exit (0);
if (!short_form)
if (!short_form)
isc_buffer_usedregion(b, &r);
isc_buffer_free(&b);
static isc_result_t
isc_region_t r;
char *rtt;
if (headers)
return (ISC_R_SUCCESS);
return (result);
if (!short_form) {
&target);
return (result);
#ifdef USEINITALWS
if (first) {
rdataset);
if (!short_form) {
if (no_rdata)
(char *)r.base);
return (result);
return (ISC_R_SUCCESS);
static isc_result_t
isc_region_t r;
if (headers)
&target);
return (result);
return (ISC_R_SUCCESS);
return (ISC_R_SUCCESS);
if (!short_form) {
!short_form ) {
return (result);
if (!short_form)
return (result);
!short_form ) {
return (result);
!short_form ) {
return (result);
return (result);
if (!short_form)
return (result);
!= EOF) {
if (querytype[0] == 0)
if (queryclass[0] == 0)
show_usage();
if (querytype[0] == 0)
if (queryclass[0] == 0)
sizeof(struct dig_lookup));