static char buf[6];
switch (class)
{
- case GNUNET_DNSPARSER_CLASS_INTERNET: return "IN";
- case GNUNET_DNSPARSER_CLASS_CHAOS: return "CHAOS";
- case GNUNET_DNSPARSER_CLASS_HESIOD: return "HESIOD";
+ case GNUNET_TUN_DNS_CLASS_INTERNET: return "IN";
+ case GNUNET_TUN_DNS_CLASS_CHAOS: return "CHAOS";
+ case GNUNET_TUN_DNS_CLASS_HESIOD: return "HESIOD";
}
GNUNET_snprintf (buf, sizeof (buf), "%u", (unsigned int) class);
return buf;
{
fprintf (stdout,
"\t\t%s %s: %s\n",
- get_class (query->class),
+ get_class (query->dns_traffic_class),
get_type (query->type),
query->name);
}
const char *format;
char buf[INET6_ADDRSTRLEN];
char *tmp;
-
+
tmp = NULL;
switch (record->type)
{
(unsigned int) record->data.soa->refresh,
(unsigned int) record->data.soa->retry,
(unsigned int) record->data.soa->expire,
- (unsigned int) record->data.soa->minimum_ttl);
+ (unsigned int) record->data.soa->minimum_ttl);
format = tmp;
}
break;
else
{
GNUNET_asprintf (&tmp,
- "service: %s, protocol: %s, domain_name = %s, priority %u, weight = %s, port = %u, target = %s",
- record->data.srv->service,
- record->data.srv->proto,
- record->data.srv->domain_name,
+ "priority %u, weight = %s, port = %u, target = %s",
(unsigned int) record->data.srv->priority,
(unsigned int) record->data.srv->weight,
(unsigned int) record->data.srv->port,
}
fprintf (stdout,
"\t\t%s %s: %s = %s (%u s)\n",
- get_class (record->class),
+ get_class (record->dns_traffic_class),
get_type (record->type),
record->name,
format,
* @param request_length number of bytes in request
* @param request udp payload of the DNS request
*/
-static void
+static void
display_request (void *cls,
struct GNUNET_DNS_RequestHandle *rh,
size_t request_length,
p->flags.authenticated_data ? "AD " : "",
p->flags.recursion_available ? "RA " : "",
return_codes[p->flags.return_code & 15],
- op_codes[p->flags.opcode & 15]);
+ op_codes[p->flags.opcode & 15]);
if (p->num_queries > 0)
fprintf (stdout,
"\tQueries:\n");
for (i=0;i<p->num_queries;i++)
display_query (&p->queries[i]);
-
+
if (p->num_answers > 0)
fprintf (stdout,
"\tAnswers:\n");
if (outbound_only)
flags |= GNUNET_DNS_FLAG_RESPONSE_MONITOR;
handle =
- GNUNET_DNS_connect (cfg,
+ GNUNET_DNS_connect (cfg,
flags,
&display_request,
NULL);