From: Mark Andrews Date: Mon, 27 May 2019 01:00:34 +0000 (+1000) Subject: log TSIG key name when sending notify X-Git-Tag: v9.15.1~11^2~2 X-Git-Url: http://git.ipfire.org/gitweb/index.cgi?a=commitdiff_plain;h=bb51694d035fc8eed58fa1a6755506e6e5a564fb;p=thirdparty%2Fbind9.git log TSIG key name when sending notify --- diff --git a/lib/dns/zone.c b/lib/dns/zone.c index 721f160ffbb..97c0c40985a 100644 --- a/lib/dns/zone.c +++ b/lib/dns/zone.c @@ -11474,9 +11474,17 @@ notify_send_toaddr(isc_task_t *task, isc_event_t *event) { } } - /* XXX: should we log the tsig key too? */ - notify_log(notify->zone, ISC_LOG_DEBUG(3), "sending notify to %s", - addrbuf); + if (key != NULL) { + char namebuf[DNS_NAME_FORMATSIZE]; + + dns_name_format(&key->name, namebuf, sizeof(namebuf)); + notify_log(notify->zone, ISC_LOG_DEBUG(3), + "sending notify to %s : TSIG (%s)", + addrbuf, namebuf); + } else { + notify_log(notify->zone, ISC_LOG_DEBUG(3), + "sending notify to %s", addrbuf); + } options = 0; if (notify->zone->view->peers != NULL) { dns_peer_t *peer = NULL;