]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
rec: Log invalid RPZ content when obtained via IXFR 12145/head
authorRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 10 Oct 2022 15:47:46 +0000 (17:47 +0200)
committerOtto Moerbeek <otto.moerbeek@open-xchange.com>
Tue, 1 Nov 2022 07:48:49 +0000 (08:48 +0100)
That kind of content was properly logged and handled when received
during the initial loading (AXFR) but not when received via an
incremental update.

(cherry picked from commit 55a99233728fc01e3946a97fb8dbb073a3003622)

pdns/rpzloader.cc

index a92ee3f8b953ca12da54e79449e8265da4cbf1f1..a528c25c2e756d063931b2feffd685e59f94fca9 100644 (file)
@@ -599,5 +599,9 @@ void RPZIXFRTracker(const std::vector<ComboAddress>& primaries, const boost::opt
       SLOG(g_log << Logger::Error << "Error while applying the update received over XFR for "<<zoneName<<", skipping the update: "<< e.what() <<endl,
            logger->error(Logr::Error, e.what(), "Exception while applying the update received over XFR, skipping", "exception", Logging::Loggable("std::exception")));
     }
+    catch (const PDNSException& e) {
+      SLOG(g_log << Logger::Error << "Error while applying the update received over XFR for "<<zoneName<<", skipping the update: "<< e.reason <<endl,
+           logger->error(Logr::Error, e.reason, "Exception while applying the update received over XFR, skipping", "exception", Logging::Loggable("PDNSException")));
+    }
   }
 }