2
0
mirror of https://gitlab.isc.org/isc-projects/bind9 synced 2025-08-29 13:38:26 +00:00

TSIG initialization moved until after config file parsing

This commit is contained in:
Brian Wellington 1999-10-27 20:00:40 +00:00
parent e552b98037
commit 24e49b2133
2 changed files with 12 additions and 6 deletions

View File

@ -274,11 +274,6 @@ setup() {
if (result != ISC_R_SUCCESS)
ns_main_earlyfatal("ns_server_init() failed: %s",
isc_result_totext(result));
result = dns_tsig_init(ns_g_mctx);
if (result != ISC_R_SUCCESS)
ns_main_earlyfatal("dns_tsig_init() failed: %s",
isc_result_totext(result));
}
static void

View File

@ -51,6 +51,7 @@
#include <dns/journal.h>
#include <dns/view.h>
#include <dns/zone.h>
#include <dns/tsig.h>
#include <dns/tkey.h>
#include <named/types.h>
@ -360,13 +361,23 @@ load_configuration(const char *filename) {
if (oconfigctx != NULL)
dns_c_ctx_delete(ns_g_lctx, &oconfigctx);
/*
* Load the TSIG information from the configuration
*/
result = dns_tsig_init(ns_g_confctx, ns_g_mctx);
if (result != ISC_R_SUCCESS)
ns_server_fatal(NS_LOGMODULE_SERVER, ISC_FALSE,
"dns_tsig_init() failed: %s",
isc_result_totext(result));
/*
* Load the TKEY information from the configuration
*/
result = dns_tkey_init(ns_g_lctx, ns_g_confctx, ns_g_mctx);
if (result != ISC_R_SUCCESS) {
ns_server_fatal(NS_LOGMODULE_SERVER, ISC_FALSE,
"TKEY init failed");
"dns_tkey_init() failed: %s",
isc_result_totext(result));
}
}