unbound-host.c File Reference

This file performs functionality like 'host', and also supports validation. More...

#include "config.h"
#include "libunbound/unbound.h"
#include <ldns/ldns.h>

Functions

static void usage ()
 Give unbound-host usage, and exit (1).
static int isip4 (const char *nm, char **res)
 determine if str is ip4 and put into reverse lookup format
static int isip6 (const char *nm, char **res)
 determine if str is ip6 and put into reverse lookup format
static char * massage_qname (const char *nm, int *reverse)
 massage input name
static int massage_type (const char *t, int reverse, int *multi)
 massage input type
static int massage_class (const char *c)
 massage input class
static const char * secure_str (struct ub_result *result)
 nice security status string
static void pretty_type (char *s, size_t len, int t)
 nice string for type
static void pretty_class (char *s, size_t len, int c)
 nice string for class
static void pretty_rcode (char *s, size_t len, int r)
 nice string for rcode
static void print_rd (int t, char *data, size_t len)
 convert and print rdata
static void pretty_rdata (char *q, char *cstr, char *tstr, int t, const char *sec, char *data, size_t len)
 pretty line of RR data for results
static void pretty_output (char *q, int t, int c, struct ub_result *result, int docname)
 pretty line of output for results
static int dnslook (struct ub_ctx *ctx, char *q, int t, int c, int docname)
 perform a lookup and printout return if domain existed
static void lookup (struct ub_ctx *ctx, const char *nm, const char *qt, const char *qc)
 perform host lookup
static void check_ub_res (int r)
 print error if any
int main (int argc, char *argv[])
 Main routine for checkconf.

Variables

static int verb = 0
 verbosity for unbound-host app
int optind
 getopt global, in case header files fail to declare it.
char * optarg
 getopt global, in case header files fail to declare it.

Detailed Description

This file performs functionality like 'host', and also supports validation.

It uses the libunbound library.


Function Documentation

static void usage ( void   )  [static]

Give unbound-host usage, and exit (1).


Variable Documentation

int optind

getopt global, in case header files fail to declare it.

char* optarg

getopt global, in case header files fail to declare it.

Generated on Thu Apr 22 00:30:17 2010 for unbound by  doxygen 1.6.3