mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-09-02 23:55:27 +00:00
Fix checkconf dnssec-policy inheritance bug
Similar to #2778, the check for 'dnssec-policy' failed to account for it being inheritable.
This commit is contained in:
@@ -0,0 +1,23 @@
|
|||||||
|
/*
|
||||||
|
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
||||||
|
*
|
||||||
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
|
*
|
||||||
|
* See the COPYRIGHT file distributed with this work for additional
|
||||||
|
* information regarding copyright ownership.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The dnssec-policy is not defined. Should also be caught if it is inherited.
|
||||||
|
*/
|
||||||
|
|
||||||
|
view "test" {
|
||||||
|
dnssec-policy "notdefined";
|
||||||
|
|
||||||
|
zone "example.net" {
|
||||||
|
type primary;
|
||||||
|
file "example.db";
|
||||||
|
};
|
||||||
|
};
|
@@ -0,0 +1,23 @@
|
|||||||
|
/*
|
||||||
|
* Copyright (C) Internet Systems Consortium, Inc. ("ISC")
|
||||||
|
*
|
||||||
|
* This Source Code Form is subject to the terms of the Mozilla Public
|
||||||
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
||||||
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
|
||||||
|
*
|
||||||
|
* See the COPYRIGHT file distributed with this work for additional
|
||||||
|
* information regarding copyright ownership.
|
||||||
|
*/
|
||||||
|
|
||||||
|
/*
|
||||||
|
* The dnssec-policy is not defined. Should also be caught if it is inherited.
|
||||||
|
*/
|
||||||
|
|
||||||
|
options {
|
||||||
|
dnssec-policy "notdefined";
|
||||||
|
};
|
||||||
|
|
||||||
|
zone "example.net" {
|
||||||
|
type primary;
|
||||||
|
file "example.db";
|
||||||
|
};
|
@@ -158,7 +158,7 @@ view "third" {
|
|||||||
allow-update {
|
allow-update {
|
||||||
"any";
|
"any";
|
||||||
};
|
};
|
||||||
auto-dnssec maintain;
|
dnssec-policy "default";
|
||||||
};
|
};
|
||||||
zone "p" {
|
zone "p" {
|
||||||
type primary;
|
type primary;
|
||||||
|
@@ -2636,6 +2636,12 @@ check_zoneconf(const cfg_obj_t *zconfig, const cfg_obj_t *voptions,
|
|||||||
*/
|
*/
|
||||||
obj = NULL;
|
obj = NULL;
|
||||||
(void)cfg_map_get(zoptions, "dnssec-policy", &obj);
|
(void)cfg_map_get(zoptions, "dnssec-policy", &obj);
|
||||||
|
if (obj == NULL && voptions != NULL) {
|
||||||
|
(void)cfg_map_get(voptions, "dnssec-policy", &obj);
|
||||||
|
}
|
||||||
|
if (obj == NULL && goptions != NULL) {
|
||||||
|
(void)cfg_map_get(goptions, "dnssec-policy", &obj);
|
||||||
|
}
|
||||||
if (obj != NULL) {
|
if (obj != NULL) {
|
||||||
const cfg_obj_t *kasps = NULL;
|
const cfg_obj_t *kasps = NULL;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user