]> git.ipfire.org Git - thirdparty/bind9.git/commitdiff
Report when loading of dhparam-file fails
authorMark Andrews <marka@isc.org>
Tue, 4 Jan 2022 01:28:08 +0000 (12:28 +1100)
committerMark Andrews <marka@isc.org>
Mon, 3 Apr 2023 02:06:04 +0000 (12:06 +1000)
prior to this loading of the configuration could fail without
an informative error message being logged.

lib/ns/listenlist.c

index c0f9e5946a92e464d321f57317b1566cb6f63c0a..a4a7c2b2e4def514d6b56c0f9cdd585b358b3216 100644 (file)
@@ -22,6 +22,7 @@
 #include <dns/acl.h>
 
 #include <ns/listenlist.h>
+#include <ns/log.h>
 
 static void
 destroy(ns_listenlist_t *list);
@@ -116,6 +117,13 @@ listenelt_create(isc_mem_t *mctx, in_port_t port, dns_acl_t *acl,
                                if (!isc_tlsctx_load_dhparams(
                                            sslctx, tls_params->dhparam_file))
                                {
+                                       isc_log_write(ns_lctx,
+                                                     NS_LOGCATEGORY_GENERAL,
+                                                     NS_LOGMODULE_INTERFACEMGR,
+                                                     ISC_LOG_ERROR,
+                                                     "loading of dhparam-file "
+                                                     "'%s' failed",
+                                                     tls_params->dhparam_file);
                                        result = ISC_R_FAILURE;
                                        goto tls_error;
                                }