From 09cf404390bde072fdc5e57373019c53664b9ba7 Mon Sep 17 00:00:00 2001 From: Remi Gacogne Date: Fri, 2 Sep 2016 09:57:54 +0200 Subject: [PATCH] rec: Ignore NS records in a RPZ zone received over IXFR They are already ignored over AXFR, but not over IXFR. Reported and based on a patch by @42wim (thanks!). (cherry picked from commit ed8c725224b5192367149897cfaaaf188ab0b910) --- pdns/reczones.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/pdns/reczones.cc b/pdns/reczones.cc index 63ccb27e3b..97e1e84fac 100644 --- a/pdns/reczones.cc +++ b/pdns/reczones.cc @@ -347,6 +347,8 @@ void RPZIXFRTracker(const ComboAddress& master, const DNSName& zone, size_t polZ luaconfsCopy.dfe.clear(0); } for(const auto& rr : remove) { // should always contain the SOA + if(rr.d_type == QType::NS) + continue; totremove++; if(rr.d_type == QType::SOA) { auto oldsr = getRR(rr); @@ -363,6 +365,8 @@ void RPZIXFRTracker(const ComboAddress& master, const DNSName& zone, size_t polZ } for(const auto& rr : add) { // should always contain the new SOA + if(rr.d_type == QType::NS) + continue; totadd++; if(rr.d_type == QType::SOA) { auto newsr = getRR(rr); -- 2.47.2