]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
rec: Fix NSEC3 next owner in SyncRes unit tests
authorRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 5 Jul 2021 16:00:37 +0000 (18:00 +0200)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 5 Jul 2021 16:00:37 +0000 (18:00 +0200)
pdns/recursordist/test-syncres_cc.cc

index 858ebaa9b92d166724c2bbc89501353b518c6eb1..6a94f060e30ba8e7845c4d03bcd55f412410f7cb 100644 (file)
@@ -487,7 +487,9 @@ LWResult::Result genericDSAndDNSKEYHandler(LWResult* res, const DNSName& domain,
           addNSECRecordToLW(domain, DNSName("+") + domain, types, 600, res->d_records);
         }
         else {
-          addNSEC3UnhashedRecordToLW(domain, auth, (DNSName("z") + domain).toString(), types, 600, res->d_records, 10, optOut);
+          DNSName next(DNSName("z") + domain);
+          next.makeUsRelative(auth);
+          addNSEC3UnhashedRecordToLW(domain, auth, next.toString(), types, 600, res->d_records, 10, optOut);
         }
 
         addRRSIG(keys, res->d_records, auth, 300, false, boost::none, boost::none, now);