]> git.ipfire.org Git - thirdparty/pdns.git/commitdiff
dnsdist: Don't try to get TLS contexts for DoQ and DoH3 frontends
authorRemi Gacogne <remi.gacogne@powerdns.com>
Mon, 3 Mar 2025 15:57:42 +0000 (16:57 +0100)
committerRemi Gacogne <remi.gacogne@powerdns.com>
Wed, 2 Apr 2025 10:29:01 +0000 (12:29 +0200)
Right now the BoringSSL context is handled by Quiche and we do not
mess with it.

pdns/dnsdistdist/dnsdist-configuration-yaml.cc

index 3fad3db70af9e20f03f562b52b15039745c1d4ae..9747a5de9b4e2fc24d1b3e830f851e1e6f0c1159 100644 (file)
@@ -239,7 +239,7 @@ static bool validateTLSConfiguration(const dnsdist::rust::settings::BindConfigur
   return true;
 }
 
-static bool handleTLSConfiguration(const dnsdist::rust::settings::BindConfiguration& bind, ClientState& state, std::shared_ptr<const TLSFrontend> parent)
+static bool handleTLSConfiguration(const dnsdist::rust::settings::BindConfiguration& bind, ClientState& state, const std::shared_ptr<const TLSFrontend>& parent)
 {
   auto tlsConfig = getTLSConfigFromRustIncomingTLS(bind.tls);
   if (!validateTLSConfiguration(bind, tlsConfig)) {
@@ -717,7 +717,7 @@ static void loadBinds(const ::rust::Vec<dnsdist::rust::settings::BindConfigurati
           if (!handleTLSConfiguration(bind, *state, tlsFrontendParent)) {
             continue;
           }
-          if (tlsFrontendParent == nullptr) {
+          if (tlsFrontendParent == nullptr && (protocol == "dot" || protocol == "doh")) {
             tlsFrontendParent = state->getTLSFrontend();
           }
         }