]> granicus.if.org Git - pdns/commitdiff
make pdnssec check-zone error about NSEC(3)s in the database
authorPeter van Dijk <peter.van.dijk@netherlabs.nl>
Fri, 23 Nov 2012 11:28:21 +0000 (11:28 +0000)
committerPeter van Dijk <peter.van.dijk@netherlabs.nl>
Fri, 23 Nov 2012 11:28:21 +0000 (11:28 +0000)
git-svn-id: svn://svn.powerdns.com/pdns/trunk/pdns@2918 d19b8d6e-7fed-0310-83ef-9ca221ded41b

pdns/pdnssec.cc

index ad140342f7c5998cdceae8ac5cb5afc8ded7015d..480e6a9c8d312efb6c7793fe465aec4e2239fb32 100644 (file)
@@ -285,6 +285,13 @@ int checkZone(UeberBackend *B, const std::string& zone)
     if(!rr.qtype.getCode())
       continue;
     
+    if(rr.qtype.getCode() == QType::NSEC || rr.qtype.getCode() == QType::NSEC3)
+    {
+      cout<<"[Error] NSEC or NSEC3 found at '"<<rr.qname<<"'. These do not belong in the database."<<endl;
+      numerrors++;
+      continue;
+    }
+
     if(rr.qtype.getCode() == QType::SOA)
     {
       fillSOAData(rr.content, sd);