From 4990dae87d6c28c8b2323d353ceca8489a3c4ca9 Mon Sep 17 00:00:00 2001 From: "W.C.A. Wijngaards" Date: Thu, 22 Oct 2020 09:26:27 +0200 Subject: [PATCH] - Fix that minimal-responses does not remove addresses from a priming query response. --- doc/Changelog | 2 ++ util/data/msgencode.c | 3 +++ 2 files changed, 5 insertions(+) diff --git a/doc/Changelog b/doc/Changelog index 776643c46..1201081d2 100644 --- a/doc/Changelog +++ b/doc/Changelog @@ -1,6 +1,8 @@ 22 October 2020: Wouter - Fix #333: Unbound Segmentation Fault w/ log_info Functions From Python Mod. + - Fix that minimal-responses does not remove addresses from a priming + query response. 21 October 2020: George - Fix #327: net/if.h check fails on some darwin versions; contribution by diff --git a/util/data/msgencode.c b/util/data/msgencode.c index be69f628a..1746cfbb8 100644 --- a/util/data/msgencode.c +++ b/util/data/msgencode.c @@ -624,6 +624,9 @@ positive_answer(struct reply_info* rep, uint16_t qtype) { for(i=0;ian_numrrsets; i++) { if(ntohs(rep->rrsets[i]->rk.type) == qtype) { + /* for priming queries, type NS, include addresses */ + if(qtype == LDNS_RR_TYPE_NS) + return 0; /* in case it is a wildcard with DNSSEC, there will * be NSEC/NSEC3 records in the authority section * that we cannot remove */ -- 2.47.2