Maintained by: NLnet Labs

dnstap not logging resolver response messages

Nikolay Edigaryev
Sun Mar 20 12:08:17 CET 2016


dnstap-log-resolver-response-messages option has no effect unless 
dnstap-log-resolver-query-messages option is also enabled.

The sample config from the dnstap website[1] works fine because it has 
both of the mentioned options set, but if one wants to log resolver 
responses only, the following config won't do:

dnstap:
    dnstap-enable: yes
    dnstap-log-resolver-response-messages: yes

[1] http://dnstap.info/Examples/

Index: dnstap/dnstap.c
===================================================================
--- dnstap/dnstap.c	(revision 3682)
+++ dnstap/dnstap.c	(working copy)
@@ -475,7 +475,7 @@
 			return;
 		dt_msg_init(env, &dm, 
DNSTAP__MESSAGE__TYPE__FORWARDER_RESPONSE);
 	} else {
-		if (!env->log_resolver_query_messages)
+		if (!env->log_resolver_response_messages)
 			return;
 		dt_msg_init(env, &dm, 
DNSTAP__MESSAGE__TYPE__RESOLVER_RESPONSE);
 	}