From: Evan Hunt Date: Wed, 17 Jun 2020 09:02:27 +0000 (-0700) Subject: add "primaries" as a synonym for "masters" in named.conf X-Git-Tag: v9.17.3~19^2~5 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=16e14353b1755111645024d06fa4225e019ba9a2;p=thirdparty%2Fbind9.git add "primaries" as a synonym for "masters" in named.conf as "type primary" is preferred over "type master" now, it makes sense to make "primaries" available as a synonym too. added a correctness check to ensure "primaries" and "masters" cannot both be used in the same zone. --- diff --git a/bin/check/named-checkconf.c b/bin/check/named-checkconf.c index a6884833b5f..4824c18d764 100644 --- a/bin/check/named-checkconf.c +++ b/bin/check/named-checkconf.c @@ -185,7 +185,7 @@ configure_zone(const char *vclass, const char *view, const cfg_obj_t *zconfig, const char *zname; const char *zfile = NULL; const cfg_obj_t *maps[4]; - const cfg_obj_t *mastersobj = NULL; + const cfg_obj_t *primariesobj = NULL; const cfg_obj_t *inviewobj = NULL; const cfg_obj_t *zoptions = NULL; const cfg_obj_t *classobj = NULL; @@ -279,8 +279,12 @@ configure_zone(const char *vclass, const char *view, const cfg_obj_t *zconfig, * Is the redirect zone configured as a slave? */ if (strcasecmp(cfg_obj_asstring(typeobj), "redirect") == 0) { - cfg_map_get(zoptions, "masters", &mastersobj); - if (mastersobj != NULL) { + cfg_map_get(zoptions, "primaries", &primariesobj); + if (primariesobj == NULL) { + cfg_map_get(zoptions, "masters", &primariesobj); + } + + if (primariesobj != NULL) { return (ISC_R_SUCCESS); } } diff --git a/bin/named/config.c b/bin/named/config.c index b32a8a05c42..a49503df004 100644 --- a/bin/named/config.c +++ b/bin/named/config.c @@ -302,7 +302,7 @@ view \"_bind\" chaos {\n\ "# END MANAGED KEYS\n\ \n\ -masters " DEFAULT_IANA_ROOT_ZONE_MASTERS " {\n\ +primaries " DEFAULT_IANA_ROOT_ZONE_PRIMARIES " {\n\ 2001:500:84::b; # b.root-servers.net\n\ 2001:500:2f::f; # f.root-servers.net\n\ 2001:7fd::1; # k.root-servers.net\n\ @@ -567,17 +567,21 @@ named_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp, } isc_result_t -named_config_getmastersdef(const cfg_obj_t *cctx, const char *name, - const cfg_obj_t **ret) { +named_config_getprimariesdef(const cfg_obj_t *cctx, const char *name, + const cfg_obj_t **ret) { isc_result_t result; - const cfg_obj_t *masters = NULL; + const cfg_obj_t *primaries = NULL; const cfg_listelt_t *elt; - result = cfg_map_get(cctx, "masters", &masters); + result = cfg_map_get(cctx, "primaries", &primaries); + if (result != ISC_R_SUCCESS) { + result = cfg_map_get(cctx, "masters", &primaries); + } if (result != ISC_R_SUCCESS) { return (result); } - for (elt = cfg_list_first(masters); elt != NULL; + + for (elt = cfg_list_first(primaries); elt != NULL; elt = cfg_list_next(elt)) { const cfg_obj_t *list; const char *listname; @@ -678,7 +682,7 @@ resume: isc_buffer_t b; addr = cfg_tuple_get(cfg_listelt_value(element), - "masterselement"); + "primarieselement"); key = cfg_tuple_get(cfg_listelt_value(element), "key"); if (!cfg_obj_issockaddr(addr)) { @@ -710,11 +714,11 @@ resume: if (j < l) { continue; } - tresult = named_config_getmastersdef(config, listname, - &list); + tresult = named_config_getprimariesdef(config, listname, + &list); if (tresult == ISC_R_NOTFOUND) { cfg_obj_log(addr, named_g_lctx, ISC_LOG_ERROR, - "masters \"%s\" not found", + "primaries \"%s\" not found", listname); result = tresult; diff --git a/bin/named/include/named/config.h b/bin/named/include/named/config.h index fa689175452..99b94895537 100644 --- a/bin/named/include/named/config.h +++ b/bin/named/include/named/config.h @@ -21,7 +21,7 @@ #include -#define DEFAULT_IANA_ROOT_ZONE_MASTERS "_default_iana_root_zone_masters" +#define DEFAULT_IANA_ROOT_ZONE_PRIMARIES "_default_iana_root_zone_primaries" isc_result_t named_config_parsedefaults(cfg_parser_t *parser, cfg_obj_t **conf); @@ -59,8 +59,8 @@ named_config_putiplist(isc_mem_t *mctx, isc_sockaddr_t **addrsp, isc_dscp_t **dscpsp, uint32_t count); isc_result_t -named_config_getmastersdef(const cfg_obj_t *cctx, const char *name, - const cfg_obj_t **ret); +named_config_getprimariesdef(const cfg_obj_t *cctx, const char *name, + const cfg_obj_t **ret); isc_result_t named_config_getipandkeylist(const cfg_obj_t *config, const cfg_obj_t *list, diff --git a/bin/named/named.conf.rst b/bin/named/named.conf.rst index fdaa8b82640..dcbc5278251 100644 --- a/bin/named/named.conf.rst +++ b/bin/named/named.conf.rst @@ -134,8 +134,8 @@ MASTERS :: masters string [ port integer ] [ dscp - integer ] { ( masters | ipv4_address [ - port integer ] | ipv6_address [ port + integer ] { ( primaries | ipv4_address + [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... }; OPTIONS @@ -155,7 +155,7 @@ OPTIONS allow-transfer { address_match_element; ... }; allow-update { address_match_element; ... }; allow-update-forwarding { address_match_element; ... }; - also-notify [ port integer ] [ dscp integer ] { ( masters | + also-notify [ port integer ] [ dscp integer ] { ( primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... }; alt-transfer-source ( ipv4_address | * ) [ port ( integer | * ) @@ -173,7 +173,7 @@ OPTIONS blackhole { address_match_element; ... }; cache-file quoted_string; catalog-zones { zone string [ default-masters [ port integer ] - [ dscp integer ] { ( masters | ipv4_address [ port + [ dscp integer ] { ( primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... } ] [ zone-directory quoted_string ] [ in-memory boolean ] [ min-update-interval duration ]; ... }; @@ -445,6 +445,16 @@ PLUGIN plugin ( query ) string [ { unspecified-text } ]; +PRIMARIES +^^^^^^^^^ + +:: + + primaries string [ port integer ] [ dscp + integer ] { ( primaries | ipv4_address + [ port integer ] | ipv6_address [ port + integer ] ) [ key string ]; ... }; + SERVER ^^^^^^ @@ -533,7 +543,7 @@ VIEW allow-transfer { address_match_element; ... }; allow-update { address_match_element; ... }; allow-update-forwarding { address_match_element; ... }; - also-notify [ port integer ] [ dscp integer ] { ( masters | + also-notify [ port integer ] [ dscp integer ] { ( primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... }; alt-transfer-source ( ipv4_address | * ) [ port ( integer | * ) @@ -545,7 +555,7 @@ VIEW auto-dnssec ( allow | maintain | off ); cache-file quoted_string; catalog-zones { zone string [ default-masters [ port integer ] - [ dscp integer ] { ( masters | ipv4_address [ port + [ dscp integer ] { ( primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... } ] [ zone-directory quoted_string ] [ in-memory boolean ] [ min-update-interval duration ]; ... }; @@ -805,7 +815,7 @@ VIEW allow-update { address_match_element; ... }; allow-update-forwarding { address_match_element; ... }; also-notify [ port integer ] [ dscp integer ] { ( - masters | ipv4_address [ port integer ] | + primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... }; alt-transfer-source ( ipv4_address | * ) [ port ( @@ -845,9 +855,10 @@ VIEW key-directory quoted_string; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port integer ] [ dscp integer ] { ( masters - | ipv4_address [ port integer ] | ipv6_address [ - port integer ] ) [ key string ]; ... }; + masters [ port integer ] [ dscp integer ] { ( + primaries | ipv4_address [ port integer ] | + ipv6_address [ port integer ] ) [ key string ]; + ... }; max-ixfr-ratio ( unlimited | percentage ); max-journal-size ( default | unlimited | sizeval ); max-records integer; @@ -868,6 +879,10 @@ VIEW notify-source-v6 ( ipv6_address | * ) [ port ( integer | * ) ] [ dscp integer ]; notify-to-soa boolean; + primaries [ port integer ] [ dscp integer ] { ( + primaries | ipv4_address [ port integer ] | + ipv6_address [ port integer ] ) [ key string ]; + ... }; request-expire boolean; request-ixfr boolean; serial-update-method ( date | increment | unixtime ); @@ -910,7 +925,7 @@ ZONE allow-transfer { address_match_element; ... }; allow-update { address_match_element; ... }; allow-update-forwarding { address_match_element; ... }; - also-notify [ port integer ] [ dscp integer ] { ( masters | + also-notify [ port integer ] [ dscp integer ] { ( primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... }; alt-transfer-source ( ipv4_address | * ) [ port ( integer | * ) @@ -948,7 +963,7 @@ ZONE key-directory quoted_string; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port integer ] [ dscp integer ] { ( masters | + masters [ port integer ] [ dscp integer ] { ( primaries | ipv4_address [ port integer ] | ipv6_address [ port integer ] ) [ key string ]; ... }; max-ixfr-ratio ( unlimited | percentage ); @@ -971,6 +986,9 @@ ZONE notify-source-v6 ( ipv6_address | * ) [ port ( integer | * ) ] [ dscp integer ]; notify-to-soa boolean; + primaries [ port integer ] [ dscp integer ] { ( primaries | + ipv4_address [ port integer ] | ipv6_address [ port + integer ] ) [ key string ]; ... }; request-expire boolean; request-ixfr boolean; serial-update-method ( date | increment | unixtime ); diff --git a/bin/named/zoneconf.c b/bin/named/zoneconf.c index 778114000f4..2f7de9e89e3 100644 --- a/bin/named/zoneconf.c +++ b/bin/named/zoneconf.c @@ -1236,8 +1236,8 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, /* * Configure master functionality. This applies - * to primary masters (type "master") and slaves - * acting as masters (type "slave"), but not to stubs. + * to primary servers (type "primary") and secondaries + * acting as primaries (type "secondary"), but not to stubs. */ if (ztype != dns_zone_stub && ztype != dns_zone_staticstub && ztype != dns_zone_redirect) @@ -1531,7 +1531,7 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, /* * Configure update-related options. These apply to - * primary masters only. + * primary servers only. */ if (ztype == dns_zone_master) { dns_acl_t *updateacl; @@ -1866,17 +1866,21 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, case dns_zone_redirect: count = 0; obj = NULL; - (void)cfg_map_get(zoptions, "masters", &obj); + (void)cfg_map_get(zoptions, "primaries", &obj); + if (obj == NULL) { + (void)cfg_map_get(zoptions, "masters", &obj); + } + /* - * Use the built-in master server list if one was not + * Use the built-in primary server list if one was not * explicitly specified and this is a root zone mirror. */ if (obj == NULL && ztype == dns_zone_mirror && dns_name_equal(dns_zone_getorigin(zone), dns_rootname)) { - result = named_config_getmastersdef( - named_g_config, DEFAULT_IANA_ROOT_ZONE_MASTERS, - &obj); + result = named_config_getprimariesdef( + named_g_config, + DEFAULT_IANA_ROOT_ZONE_PRIMARIES, &obj); RETERR(result); } if (obj != NULL) { @@ -1885,13 +1889,13 @@ named_zone_configure(const cfg_obj_t *config, const cfg_obj_t *vconfig, RETERR(named_config_getipandkeylist(config, obj, mctx, &ipkl)); - result = dns_zone_setmasterswithkeys( + result = dns_zone_setprimarieswithkeys( mayberaw, ipkl.addrs, ipkl.keys, ipkl.count); count = ipkl.count; dns_ipkeylist_clear(mctx, &ipkl); RETERR(result); } else { - result = dns_zone_setmasters(mayberaw, NULL, 0); + result = dns_zone_setprimaries(mayberaw, NULL, 0); } RETERR(result); diff --git a/bin/tests/system/addzone/ns3/named1.conf.in b/bin/tests/system/addzone/ns3/named1.conf.in index d802506f218..f6f382b5495 100644 --- a/bin/tests/system/addzone/ns3/named1.conf.in +++ b/bin/tests/system/addzone/ns3/named1.conf.in @@ -30,6 +30,6 @@ zone "." { file "redirect.db"; }; -masters "testmaster" { +primaries "testmaster" { 192.5.5.241; }; diff --git a/bin/tests/system/addzone/tests.sh b/bin/tests/system/addzone/tests.sh index a8d4e1d43c7..c7fc95f0d9a 100755 --- a/bin/tests/system/addzone/tests.sh +++ b/bin/tests/system/addzone/tests.sh @@ -686,7 +686,7 @@ status=`expr $status + $ret` echo_i "check delzone after reconfig failure ($n)" ret=0 -$RNDCCMD 10.53.0.3 addzone 'inlineslave.example. IN { type slave; file "inlineslave.db"; masterfile-format text; masters { testmaster; }; };' > /dev/null 2>&1 || ret=1 +$RNDCCMD 10.53.0.3 addzone 'inlineslave.example. IN { type slave; file "inlineslave.db"; masterfile-format text; primaries { testmaster; }; };' > /dev/null 2>&1 || ret=1 copy_setports ns3/named2.conf.in ns3/named.conf rndc_reconfig ns3 10.53.0.3 $RNDCCMD 10.53.0.3 delzone inlineslave.example > /dev/null 2>&1 || ret=1 diff --git a/bin/tests/system/auth/ns2/named.conf.in b/bin/tests/system/auth/ns2/named.conf.in index 33d5fd120b6..89b4d4c5038 100644 --- a/bin/tests/system/auth/ns2/named.conf.in +++ b/bin/tests/system/auth/ns2/named.conf.in @@ -23,12 +23,12 @@ options { zone example.net { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "example.net.bk"; }; zone example.com { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "example.com.bk"; }; diff --git a/bin/tests/system/autosign/ns3/named.conf.in b/bin/tests/system/autosign/ns3/named.conf.in index 35cb0587a6d..141a3b8e7a3 100644 --- a/bin/tests/system/autosign/ns3/named.conf.in +++ b/bin/tests/system/autosign/ns3/named.conf.in @@ -45,13 +45,13 @@ zone "." { zone "example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "example.bk"; }; zone "bar" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "bar.bk"; }; diff --git a/bin/tests/system/cacheclean/ns2/named.conf.in b/bin/tests/system/cacheclean/ns2/named.conf.in index 4fd5328e865..c608db31cec 100644 --- a/bin/tests/system/cacheclean/ns2/named.conf.in +++ b/bin/tests/system/cacheclean/ns2/named.conf.in @@ -45,5 +45,5 @@ zone "flushtest.example" { zone "expire-test" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; diff --git a/bin/tests/system/case/ns2/named.conf.in b/bin/tests/system/case/ns2/named.conf.in index 473444ac29d..145f106e448 100644 --- a/bin/tests/system/case/ns2/named.conf.in +++ b/bin/tests/system/case/ns2/named.conf.in @@ -28,11 +28,11 @@ options { zone "example" { type slave; file "example.bk"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; zone "dynamic" { type slave; file "dynamic.bk"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; diff --git a/bin/tests/system/catz/ns2/named.conf.in b/bin/tests/system/catz/ns2/named.conf.in index ee83efbee46..55a6ae62a43 100644 --- a/bin/tests/system/catz/ns2/named.conf.in +++ b/bin/tests/system/catz/ns2/named.conf.in @@ -47,25 +47,25 @@ options { zone "catalog1.example" { type slave; file "catalog1.example.db"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; zone "catalog2.example" { type slave; file "catalog2.example.db"; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; }; zone "catalog3.example" { type slave; file "catalog3.example.db"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; zone "catalog4.example" { type slave; file "catalog4.example.db"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; key tsig_key. { diff --git a/bin/tests/system/checkconf/bad-masters-dup.conf b/bin/tests/system/checkconf/bad-masters-dup.conf new file mode 100644 index 00000000000..18dc4590da0 --- /dev/null +++ b/bin/tests/system/checkconf/bad-masters-dup.conf @@ -0,0 +1,16 @@ +/* + * 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. + */ + +zone "example.net" { + type secondary; + primaries { 192.168.1.1; }; + masters { 192.168.1.2; }; +}; diff --git a/bin/tests/system/dnssec/ns3/named.conf.in b/bin/tests/system/dnssec/ns3/named.conf.in index 53bfb434581..c632e7e9cf9 100644 --- a/bin/tests/system/dnssec/ns3/named.conf.in +++ b/bin/tests/system/dnssec/ns3/named.conf.in @@ -42,7 +42,7 @@ zone "." { zone "example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "example.bk"; }; @@ -174,7 +174,7 @@ zone "multiple.example" { zone "rfc2335.example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "rfc2335.example.bk"; }; @@ -247,7 +247,7 @@ zone "split-smart.example" { zone "nsec3chain-test" { type slave; file "nsec3chain-test.bk"; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; }; zone "expiring.example" { diff --git a/bin/tests/system/dnssec/ns4/named4.conf.in b/bin/tests/system/dnssec/ns4/named4.conf.in index d73c36f8c09..22217f36c41 100644 --- a/bin/tests/system/dnssec/ns4/named4.conf.in +++ b/bin/tests/system/dnssec/ns4/named4.conf.in @@ -65,11 +65,11 @@ view auth { zone secure.example { type slave; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; }; zone insecure.secure.example { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; }; }; diff --git a/bin/tests/system/dnssec/ns7/named.conf.in b/bin/tests/system/dnssec/ns7/named.conf.in index 31e3f85cdce..dd4cfd9a3cf 100644 --- a/bin/tests/system/dnssec/ns7/named.conf.in +++ b/bin/tests/system/dnssec/ns7/named.conf.in @@ -32,31 +32,31 @@ zone "." { zone "nsec3.example" { type slave; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; file "nsec3.example.bk"; }; zone "optout.example" { type slave; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; file "optout.example.bk"; }; zone "nsec3-unknown.example" { type slave; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; file "nsec3-unknown.example.bk"; }; zone "optout-unknown.example" { type slave; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; file "optout-unknown.example.bk"; }; zone "multiple.example" { type slave; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; file "multiple.example.bk"; }; diff --git a/bin/tests/system/dscp/ns2/named.conf.in b/bin/tests/system/dscp/ns2/named.conf.in index 4edc7e7ddba..0b4fa4b4ab7 100644 --- a/bin/tests/system/dscp/ns2/named.conf.in +++ b/bin/tests/system/dscp/ns2/named.conf.in @@ -26,5 +26,5 @@ options { zone "." { type slave; file "root.bk"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; diff --git a/bin/tests/system/dscp/ns5/named.conf.in b/bin/tests/system/dscp/ns5/named.conf.in index dc2bb6089ed..88a7ac1b5aa 100644 --- a/bin/tests/system/dscp/ns5/named.conf.in +++ b/bin/tests/system/dscp/ns5/named.conf.in @@ -27,5 +27,5 @@ options { zone "." { type slave; file "root.bk"; - masters { 10.53.0.4; }; + primaries { 10.53.0.4; }; }; diff --git a/bin/tests/system/dscp/ns7/named.conf.in b/bin/tests/system/dscp/ns7/named.conf.in index 25ed20ac634..36932a458c1 100644 --- a/bin/tests/system/dscp/ns7/named.conf.in +++ b/bin/tests/system/dscp/ns7/named.conf.in @@ -30,5 +30,5 @@ zone "." { transfer-source 10.53.0.7 dscp 46; notify-source 10.53.0.7 dscp 46; alt-transfer-source 10.53.0.7 dscp 46; - masters { 10.53.0.4; }; + primaries { 10.53.0.4; }; }; diff --git a/bin/tests/system/inline/ns3/named.conf.in b/bin/tests/system/inline/ns3/named.conf.in index a8c434dc025..c5f467f4445 100644 --- a/bin/tests/system/inline/ns3/named.conf.in +++ b/bin/tests/system/inline/ns3/named.conf.in @@ -34,7 +34,7 @@ options { zone "bits" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; allow-update-forwarding { any; }; @@ -46,7 +46,7 @@ server 10.53.0.4 { request-ixfr no; }; zone "noixfr" { type slave; - masters { 10.53.0.4; }; + primaries { 10.53.0.4; }; inline-signing yes; auto-dnssec maintain; allow-update-forwarding { any; }; @@ -90,7 +90,7 @@ zone "expired" { zone "retransfer" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; file "retransfer.bk"; @@ -114,7 +114,7 @@ zone "externalkey" { zone "retransfer3" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; file "retransfer3.bk"; @@ -122,7 +122,7 @@ zone "retransfer3" { zone "inactiveksk" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; dnssec-dnskey-kskonly yes; @@ -131,7 +131,7 @@ zone "inactiveksk" { zone "inactivezsk" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; file "inactivezsk.bk"; @@ -139,7 +139,7 @@ zone "inactivezsk" { zone "nokeys" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; file "nokeys.bk"; @@ -163,7 +163,7 @@ zone "removedkeys-primary" { zone "removedkeys-secondary" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; inline-signing yes; auto-dnssec maintain; file "removedkeys-secondary.bk"; diff --git a/bin/tests/system/ixfr/ns4/named.conf.in b/bin/tests/system/ixfr/ns4/named.conf.in index 086211684a6..601aed88a5b 100644 --- a/bin/tests/system/ixfr/ns4/named.conf.in +++ b/bin/tests/system/ixfr/ns4/named.conf.in @@ -36,13 +36,13 @@ view "primary" { zone "test" IN { type slave; file "mytest.db"; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; max-ixfr-ratio unlimited; }; zone "sub.test" IN { type slave; file "subtest.db"; request-ixfr no; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; }; }; diff --git a/bin/tests/system/ixfr/ns5/named.conf.in b/bin/tests/system/ixfr/ns5/named.conf.in index 220b1d39a27..71129f6a0bc 100644 --- a/bin/tests/system/ixfr/ns5/named.conf.in +++ b/bin/tests/system/ixfr/ns5/named.conf.in @@ -37,12 +37,12 @@ view "primary" { zone "test" IN { type slave; file "mytest.db"; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; }; zone "sub.test" IN { type slave; file "subtest.db"; request-ixfr no; - masters { 10.53.0.3; }; + primaries { 10.53.0.3; }; }; }; diff --git a/bin/tests/system/kasp/ns3/named.conf.in b/bin/tests/system/kasp/ns3/named.conf.in index 8b71cab1f06..39460d5f1b7 100644 --- a/bin/tests/system/kasp/ns3/named.conf.in +++ b/bin/tests/system/kasp/ns3/named.conf.in @@ -82,7 +82,7 @@ zone "dnssec-keygen.kasp" { /* A secondary zone with dnssec-policy. */ zone "secondary.kasp" { type secondary; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "secondary.kasp.db"; dnssec-policy "rsasha1"; }; diff --git a/bin/tests/system/masterformat/ns2/named.conf.in b/bin/tests/system/masterformat/ns2/named.conf.in index fb519466f40..d4ce9713217 100644 --- a/bin/tests/system/masterformat/ns2/named.conf.in +++ b/bin/tests/system/masterformat/ns2/named.conf.in @@ -28,26 +28,26 @@ zone "example" { zone "transfer1" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "transfer.db.raw"; }; zone "transfer2" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; masterfile-format text; file "transfer.db.txt"; }; zone "transfer3" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "formerly-text.db"; }; zone "transfer4" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; masterfile-format text; masterfile-style full; file "transfer.db.full"; @@ -55,7 +55,7 @@ zone "transfer4" { zone "large" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; masterfile-format raw; file "large.bk"; }; diff --git a/bin/tests/system/mirror/ns3/named.conf.in b/bin/tests/system/mirror/ns3/named.conf.in index e851b8cbf1a..4ee23c5554a 100644 --- a/bin/tests/system/mirror/ns3/named.conf.in +++ b/bin/tests/system/mirror/ns3/named.conf.in @@ -39,59 +39,59 @@ zone "." { zone "." { type mirror; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "root.db.mirror"; }; zone "initially-unavailable" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "initially-unavailable.db.mirror"; use-alt-transfer-source no; }; zone "verify-axfr" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-axfr.db.mirror"; }; zone "verify-csk" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-csk.db.mirror"; }; zone "verify-ixfr" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-ixfr.db.mirror"; masterfile-format text; }; zone "verify-load" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-load.db.mirror"; masterfile-format text; }; zone "verify-reconfig" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-reconfig.db.mirror"; masterfile-format text; }; zone "verify-unsigned" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-unsigned.db.mirror"; }; zone "verify-untrusted" { type mirror; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "verify-untrusted.db.mirror"; }; diff --git a/bin/tests/system/notify/ns2/named.conf.in b/bin/tests/system/notify/ns2/named.conf.in index 2e5bd287409..464503d2871 100644 --- a/bin/tests/system/notify/ns2/named.conf.in +++ b/bin/tests/system/notify/ns2/named.conf.in @@ -43,9 +43,9 @@ zone "example" { also-notify { /* empty */ }; }; -masters noport { 10.53.0.4; }; +primaries noport { 10.53.0.4; }; -masters x21 port @EXTRAPORT1@ { noport; }; +primaries x21 port @EXTRAPORT1@ { noport; }; zone x1 { type master; file "generic.db"; also-notify { 10.53.0.3; }; }; zone x2 { type master; file "generic.db"; also-notify { 10.53.0.3; }; }; diff --git a/bin/tests/system/notify/ns3/named.conf.in b/bin/tests/system/notify/ns3/named.conf.in index 0c3250748ba..f0e47c116a5 100644 --- a/bin/tests/system/notify/ns3/named.conf.in +++ b/bin/tests/system/notify/ns3/named.conf.in @@ -28,6 +28,6 @@ zone "." { zone "example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "example.bk"; }; diff --git a/bin/tests/system/notify/ns4/named.conf.in b/bin/tests/system/notify/ns4/named.conf.in index 57e2a53d90b..72a737f97b0 100644 --- a/bin/tests/system/notify/ns4/named.conf.in +++ b/bin/tests/system/notify/ns4/named.conf.in @@ -28,6 +28,6 @@ zone "." { zone "x21" { type slave; - masters { 10.53.0.2 port @PORT@; }; + primaries { 10.53.0.2 port @PORT@; }; file "x21.bk"; }; diff --git a/bin/tests/system/notify/ns5/named.conf.in b/bin/tests/system/notify/ns5/named.conf.in index 2976bfc1664..7fe80f50e2e 100644 --- a/bin/tests/system/notify/ns5/named.conf.in +++ b/bin/tests/system/notify/ns5/named.conf.in @@ -50,7 +50,7 @@ view "b" { match-clients { key "b"; }; zone "x21" { type slave; - masters { 10.53.0.5 key "a"; }; + primaries { 10.53.0.5 key "a"; }; file "x21.bk-b"; notify no; }; @@ -60,7 +60,7 @@ view "c" { match-clients { key "c"; }; zone "x21" { type slave; - masters { 10.53.0.5 key "a"; }; + primaries { 10.53.0.5 key "a"; }; file "x21.bk-c"; notify no; }; diff --git a/bin/tests/system/nsupdate/ns1/named.conf.in b/bin/tests/system/nsupdate/ns1/named.conf.in index e7b6adb39e1..7ed8e14429f 100644 --- a/bin/tests/system/nsupdate/ns1/named.conf.in +++ b/bin/tests/system/nsupdate/ns1/named.conf.in @@ -69,7 +69,7 @@ zone "other.nil" { allow-transfer { any; }; }; -masters othermasters { +primaries others { 10.53.0.2 port @PORT@; 10.53.0.2 port @PORT@ key altkey; }; @@ -81,7 +81,7 @@ zone "update.nil" { check-mx fail; allow-update { any; }; allow-transfer { any; }; - also-notify { othermasters; }; + also-notify { others; }; }; zone "unixtime.nil" { diff --git a/bin/tests/system/nsupdate/ns2/named.conf.in b/bin/tests/system/nsupdate/ns2/named.conf.in index b7038430bd9..16a4a8583de 100644 --- a/bin/tests/system/nsupdate/ns2/named.conf.in +++ b/bin/tests/system/nsupdate/ns2/named.conf.in @@ -41,7 +41,7 @@ view alternate { zone "update.nil" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "update.alt.bk"; allow-transfer { any; }; }; @@ -52,14 +52,14 @@ view primary { zone "example.nil" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "example.bk"; allow-transfer { any; }; }; zone "update.nil" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "update.bk"; allow-transfer { any; }; }; diff --git a/bin/tests/system/nsupdate/ns3/named.conf.in b/bin/tests/system/nsupdate/ns3/named.conf.in index 504d6ebaa3a..c9ca9c2e9c2 100644 --- a/bin/tests/system/nsupdate/ns3/named.conf.in +++ b/bin/tests/system/nsupdate/ns3/named.conf.in @@ -44,7 +44,7 @@ zone "dnskey.test" { zone "many.test" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; allow-update-forwarding { any; }; file "many.test.bk"; }; diff --git a/bin/tests/system/rpz/dnsrpzd.conf.in b/bin/tests/system/rpz/dnsrpzd.conf.in index 7b0afbfc216..bc45808ebb7 100644 --- a/bin/tests/system/rpz/dnsrpzd.conf.in +++ b/bin/tests/system/rpz/dnsrpzd.conf.in @@ -41,20 +41,20 @@ zone "bl17" {type master; file "../ns5/bl.db"; }; zone "bl18" {type master; file "../ns5/bl.db"; }; zone "bl19" {type master; file "../ns5/bl.db"; }; -zone "bl" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-2" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-given" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-passthru" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-no-op" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-disabled" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-nodata" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-nxdomain" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-cname" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-wildcname" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-garden" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-drop" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl-tcp-only" {type slave; masters port @PORT@ { 10.53.0.3; }; }; -zone "bl.tld2" {type slave; masters port @PORT@ { 10.53.0.3; }; }; +zone "bl" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-2" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-given" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-passthru" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-no-op" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-disabled" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-nodata" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-nxdomain" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-cname" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-wildcname" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-garden" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-drop" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl-tcp-only" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; +zone "bl.tld2" {type slave; primaries port @PORT@ { 10.53.0.3; }; }; -zone "policy1" {type slave; masters port @PORT@ { 10.53.0.6; }; }; -zone "policy2" {type slave; masters port @PORT@ { 10.53.0.7; }; }; +zone "policy1" {type slave; primaries port @PORT@ { 10.53.0.6; }; }; +zone "policy2" {type slave; primaries port @PORT@ { 10.53.0.7; }; }; diff --git a/bin/tests/system/rpz/ns3/named.conf.in b/bin/tests/system/rpz/ns3/named.conf.in index eec06baeb60..2c6c4a03354 100644 --- a/bin/tests/system/rpz/ns3/named.conf.in +++ b/bin/tests/system/rpz/ns3/named.conf.in @@ -102,7 +102,7 @@ zone "bl-drop." {type master; file "bl-drop.db"; zone "bl-tcp-only." {type master; file "bl-tcp-only.db"; allow-update {any;};}; -zone "bl.tld2." {type slave; file "bl.tld2.db"; masters {10.53.0.2;}; +zone "bl.tld2." {type slave; file "bl.tld2.db"; primaries {10.53.0.2;}; request-ixfr no; masterfile-format text;}; zone "crash1.tld2" {type master; file "crash1"; notify no;}; @@ -117,6 +117,6 @@ zone "manual-update-rpz." { zone "fast-expire." { type secondary; file "fast-expire.db"; - masters { 10.53.0.5; }; + primaries { 10.53.0.5; }; notify no; }; diff --git a/bin/tests/system/rpz/ns6/named.conf.in b/bin/tests/system/rpz/ns6/named.conf.in index c34546dc47b..d5bf866a313 100644 --- a/bin/tests/system/rpz/ns6/named.conf.in +++ b/bin/tests/system/rpz/ns6/named.conf.in @@ -51,7 +51,7 @@ include "../trusted.conf"; zone "policy1" { type slave; - masters { 10.53.0.5; }; + primaries { 10.53.0.5; }; file "empty.db"; also-notify { 10.53.0.3 port @EXTRAPORT1@; }; notify-delay 0; diff --git a/bin/tests/system/rpz/ns7/named.conf.in b/bin/tests/system/rpz/ns7/named.conf.in index f92b01c06ca..2d135058a30 100644 --- a/bin/tests/system/rpz/ns7/named.conf.in +++ b/bin/tests/system/rpz/ns7/named.conf.in @@ -48,7 +48,7 @@ include "../trusted.conf"; zone "policy2" { type slave; - masters { 10.53.0.5; }; + primaries { 10.53.0.5; }; file "policy2.db"; also-notify { 10.53.0.3 port @EXTRAPORT1@; }; notify-delay 0; diff --git a/bin/tests/system/rrsetorder/ns2/named.conf.in b/bin/tests/system/rrsetorder/ns2/named.conf.in index 2f13d66c717..3ebbf76783e 100644 --- a/bin/tests/system/rrsetorder/ns2/named.conf.in +++ b/bin/tests/system/rrsetorder/ns2/named.conf.in @@ -31,6 +31,6 @@ options { zone "." { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "root.bk"; }; diff --git a/bin/tests/system/serve-stale/ns3/named.conf.in b/bin/tests/system/serve-stale/ns3/named.conf.in index ac808303729..c37aa9c2565 100644 --- a/bin/tests/system/serve-stale/ns3/named.conf.in +++ b/bin/tests/system/serve-stale/ns3/named.conf.in @@ -33,6 +33,6 @@ options { zone "." { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "root.bk"; }; diff --git a/bin/tests/system/serve-stale/ns4/named.conf.in b/bin/tests/system/serve-stale/ns4/named.conf.in index cd255b06d44..4cd8bc4b64a 100644 --- a/bin/tests/system/serve-stale/ns4/named.conf.in +++ b/bin/tests/system/serve-stale/ns4/named.conf.in @@ -33,6 +33,6 @@ options { zone "." { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "root.bk"; }; diff --git a/bin/tests/system/statistics/ns3/named.conf.in b/bin/tests/system/statistics/ns3/named.conf.in index 73bd5b57f8e..504ad540e63 100644 --- a/bin/tests/system/statistics/ns3/named.conf.in +++ b/bin/tests/system/statistics/ns3/named.conf.in @@ -53,5 +53,5 @@ zone "example" { zone "a-slave" { type slave; file "slave.bk"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; diff --git a/bin/tests/system/statschannel/ns3/named.conf.in b/bin/tests/system/statschannel/ns3/named.conf.in index e78cff9a7ad..cabe068791e 100644 --- a/bin/tests/system/statschannel/ns3/named.conf.in +++ b/bin/tests/system/statschannel/ns3/named.conf.in @@ -37,5 +37,5 @@ controls { zone "example" { type secondary; file "example.db"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; diff --git a/bin/tests/system/stub/ns3/named.conf.in b/bin/tests/system/stub/ns3/named.conf.in index 4916fab3364..b21509ae046 100644 --- a/bin/tests/system/stub/ns3/named.conf.in +++ b/bin/tests/system/stub/ns3/named.conf.in @@ -35,5 +35,5 @@ zone "example" { zone "child.example" { type stub; file "child.example.st"; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; }; diff --git a/bin/tests/system/unknown/ns2/named.conf.in b/bin/tests/system/unknown/ns2/named.conf.in index 2571626bd7d..0be791ea4fe 100644 --- a/bin/tests/system/unknown/ns2/named.conf.in +++ b/bin/tests/system/unknown/ns2/named.conf.in @@ -24,7 +24,7 @@ options { view "in" { zone "example." { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "example-in.bk"; }; }; diff --git a/bin/tests/system/unknown/ns3/named.conf.in b/bin/tests/system/unknown/ns3/named.conf.in index 2ccb07421ed..056e3ac4b30 100644 --- a/bin/tests/system/unknown/ns3/named.conf.in +++ b/bin/tests/system/unknown/ns3/named.conf.in @@ -24,7 +24,7 @@ options { view "in" { zone "example." { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; inline-signing yes; auto-dnssec maintain; file "example-in.bk"; diff --git a/bin/tests/system/upforwd/ns2/named.conf.in b/bin/tests/system/upforwd/ns2/named.conf.in index bce4809b595..2a609e4c206 100644 --- a/bin/tests/system/upforwd/ns2/named.conf.in +++ b/bin/tests/system/upforwd/ns2/named.conf.in @@ -24,11 +24,11 @@ options { zone "example" { type slave; file "example.bk"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; zone "example2" { type slave; file "example2.bk"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; diff --git a/bin/tests/system/upforwd/ns3/named.conf.in b/bin/tests/system/upforwd/ns3/named.conf.in index d037e745e85..ded5d7348ba 100644 --- a/bin/tests/system/upforwd/ns3/named.conf.in +++ b/bin/tests/system/upforwd/ns3/named.conf.in @@ -25,14 +25,14 @@ zone "example" { type slave; file "example.bk"; allow-update-forwarding { any; }; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; zone "example2" { type slave; file "example2.bk"; allow-update-forwarding { any; }; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; }; zone "nomaster" { @@ -40,5 +40,5 @@ zone "nomaster" { file "nomaster1.db"; allow-update-forwarding { any; }; masterfile-format text; - masters { 10.53.0.4; }; + primaries { 10.53.0.4; }; }; diff --git a/bin/tests/system/views/ns3/named2.conf.in b/bin/tests/system/views/ns3/named2.conf.in index f72255c29a9..63d861082db 100644 --- a/bin/tests/system/views/ns3/named2.conf.in +++ b/bin/tests/system/views/ns3/named2.conf.in @@ -38,7 +38,7 @@ zone "." { zone "example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "internal.bk"; }; diff --git a/bin/tests/system/xfer/ns2/named.conf.in b/bin/tests/system/xfer/ns2/named.conf.in index 547a9b0d4c0..d4021fad3c9 100644 --- a/bin/tests/system/xfer/ns2/named.conf.in +++ b/bin/tests/system/xfer/ns2/named.conf.in @@ -60,7 +60,7 @@ zone "tsigzone" { zone "slave" { type slave; file "slave.db"; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; masterfile-format text; }; @@ -68,5 +68,5 @@ zone "mapped" { type slave; file "mapped.db"; masterfile-format text; - masters { 10.53.0.100; }; + primaries { 10.53.0.100; }; }; diff --git a/bin/tests/system/xfer/ns3/named.conf.in b/bin/tests/system/xfer/ns3/named.conf.in index 7e8955dce34..49110b73c57 100644 --- a/bin/tests/system/xfer/ns3/named.conf.in +++ b/bin/tests/system/xfer/ns3/named.conf.in @@ -42,13 +42,13 @@ zone "." { zone "example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "example.bk"; }; zone "master" { type slave; - masters { 10.53.0.6; }; + primaries { 10.53.0.6; }; file "master.bk"; }; @@ -58,20 +58,20 @@ server 10.53.0.2 { zone "tsigzone" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "tsigzone.bk"; allow-transfer { key tsigzone.; }; }; zone "mapped" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; masterfile-format map; file "mapped.bk"; }; zone "xfer-stats" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "xfer-stats.bk"; }; diff --git a/bin/tests/system/xfer/ns6/named.conf.in b/bin/tests/system/xfer/ns6/named.conf.in index 5983f982c24..761e96ee64a 100644 --- a/bin/tests/system/xfer/ns6/named.conf.in +++ b/bin/tests/system/xfer/ns6/named.conf.in @@ -42,26 +42,26 @@ zone "master" { zone "slave" { type slave; notify no; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "slave.bk"; }; zone "edns-expire" { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "edns-expire.bk"; }; zone "axfr-too-big" { type slave; max-records 30; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "axfr-too-big.bk"; }; zone "ixfr-too-big" { type slave; max-records 30; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "ixfr-too-big.bk"; }; diff --git a/bin/tests/system/xfer/ns7/named.conf.in b/bin/tests/system/xfer/ns7/named.conf.in index 04f1e4efe54..9b2652cfdbc 100644 --- a/bin/tests/system/xfer/ns7/named.conf.in +++ b/bin/tests/system/xfer/ns7/named.conf.in @@ -25,7 +25,7 @@ options { listen-on-v6 { none; }; recursion no; notify yes; - ixfr-from-differences slave; + ixfr-from-differences secondary; check-integrity no; }; @@ -35,18 +35,18 @@ zone "." { }; zone "master2" { - type master; + type primary; file "master2.db"; }; zone "slave" { - type slave; - masters { 10.53.0.1; }; + type secondary; + primaries { 10.53.0.1; }; file "slave.bk"; }; zone "edns-expire" { - type slave; - masters { 10.53.0.6; }; + type secondary; + primaries { 10.53.0.6; }; file "edns-expire.bk"; }; diff --git a/bin/tests/system/xfer/tests.sh b/bin/tests/system/xfer/tests.sh index 9b853be55e1..38acf8f1d75 100755 --- a/bin/tests/system/xfer/tests.sh +++ b/bin/tests/system/xfer/tests.sh @@ -185,7 +185,7 @@ if test $tmp != 0 ; then echo_i "failed"; fi status=$((status+tmp)) n=$((n+1)) -echo_i "testing ixfr-from-differences master; (slave zone) ($n)" +echo_i "testing ixfr-from-differences master; (secondary zone) ($n)" tmp=0 $DIG $DIGOPTS slave. \ @@ -206,7 +206,7 @@ if test $tmp != 0 ; then echo_i "failed"; fi status=$((status+tmp)) n=$((n+1)) -echo_i "testing ixfr-from-differences slave; (master zone) ($n)" +echo_i "testing ixfr-from-differences secondary; (secondary zone) ($n)" tmp=0 # ns7 has a journal iff it generates an IXFR. @@ -217,7 +217,7 @@ if test $tmp != 0 ; then echo_i "failed"; fi status=$((status+tmp)) n=$((n+1)) -echo_i "testing ixfr-from-differences slave; (slave zone) ($n)" +echo_i "testing ixfr-from-differences secondary; (secondary zone) ($n)" tmp=0 $DIG $DIGOPTS slave. \ @@ -261,11 +261,11 @@ sendcmd < ans5/goodaxfr # Initially, ns4 is not authoritative for anything. # Now that ans is up and running with the right data, we make ns4 -# a slave for nil. +# a secondary for nil. cat <>ns4/named.conf zone "nil" { - type slave; + type secondary; file "nil.db"; masters { 10.53.0.5 key tsig_key; }; }; diff --git a/bin/tests/system/xferquota/ns2/named.conf.in b/bin/tests/system/xferquota/ns2/named.conf.in index 8b68164edd9..5c1efdc710e 100644 --- a/bin/tests/system/xferquota/ns2/named.conf.in +++ b/bin/tests/system/xferquota/ns2/named.conf.in @@ -31,7 +31,7 @@ zone "." { zone "changing." { type slave; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "changing.bk"; }; diff --git a/bin/tests/system/zero/ns4/named.conf.in b/bin/tests/system/zero/ns4/named.conf.in index 2fc72b67250..0b81bca415f 100644 --- a/bin/tests/system/zero/ns4/named.conf.in +++ b/bin/tests/system/zero/ns4/named.conf.in @@ -23,7 +23,7 @@ options { zone "example" { type slave; - masters { 10.53.0.2; }; + primaries { 10.53.0.2; }; file "example.bk"; }; diff --git a/bin/tests/system/zonechecks/ns2/named.conf.in b/bin/tests/system/zonechecks/ns2/named.conf.in index cd0f7ec24ba..ef878a6002a 100644 --- a/bin/tests/system/zonechecks/ns2/named.conf.in +++ b/bin/tests/system/zonechecks/ns2/named.conf.in @@ -35,6 +35,6 @@ controls { zone "master.example" { type secondary; - masters { 10.53.0.1; }; + primaries { 10.53.0.1; }; file "slave.db"; }; diff --git a/doc/arm/reference.rst b/doc/arm/reference.rst index 83a39175339..148e0449181 100644 --- a/doc/arm/reference.rst +++ b/doc/arm/reference.rst @@ -29,8 +29,8 @@ file documentation: ``address_match_list`` A list of one or more ``ip_addr``, ``ip_prefix``, ``key_id``, or ``acl_name`` elements, see :ref:`address_match_lists`. - ``masters_list`` - A named list of one or more ``ip_addr`` with optional ``key_id`` and/or ``ip_port``. A ``masters_list`` may include other ``masters_lists``. + ``primaries_list`` + A named list of one or more ``ip_addr`` with optional ``key_id`` and/or ``ip_port``. A ``primaries_list`` may include other ``primaries_lists``. ``domain_name`` A quoted string which is used as a DNS name, for example "``my.test.domain``". @@ -272,11 +272,14 @@ The following statements are supported: Specifies what the server logs, and where the log messages are sent. ``masters`` - Defines a named masters list for inclusion in stub and secondary zones' ``masters`` or ``also-notify`` lists. + Synonym for ``primaries``. ``options`` Controls global server configuration options and sets defaults for other statements. + ``primaries`` + Defines a named list of servers for inclusion in stub and secondary zones' ``primaries`` or ``also-notify`` lists. (Note: this is a synonym for the original keyword ``masters``, which can still be used, but is no longer the preferred terminology.) + ``server`` Sets certain configuration options on a per-server basis. @@ -837,21 +840,23 @@ At ``debug`` level 4 or higher, the detailed context information logged at ``debug`` level 2 is logged for errors other than SERVFAIL and for negative responses such as NXDOMAIN. -.. _masters_grammar: +.. _primaries_grammar: -``masters`` Statement Grammar +``primaries`` Statement Grammar ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -.. include:: ../misc/masters.grammar.rst +.. include:: ../misc/primaries.grammar.rst -.. _masters_statement: +.. _primaries_statement: -``masters`` Statement Definition and Usage +``primaries`` Statement Definition and Usage ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ -``masters`` lists allow for a common set of masters to be easily used by -multiple stub and secondary zones in their ``masters`` or ``also-notify`` -lists. +``primaries`` lists allow for a common set of primary servers to be easily +used by multiple stub and secondary zones in their ``primaries`` or +``also-notify`` lists. (Note: ``primaries`` is a synonym for the original +keyword ``masters``, which can still be used, but is no longer the +preferred terminology.) .. _options_grammar: @@ -1721,15 +1726,16 @@ Boolean Options sections. The default is ``no``. ``notify`` - If ``yes`` (the default), DNS NOTIFY messages are sent when a zone - the server is authoritative for changes; see :ref:`notify`. + If set to ``yes`` (the default), DNS NOTIFY messages are sent when a + zone the server is authoritative for changes; see :ref:`notify`. The messages are sent to the servers listed in the zone's NS records (except the primary server identified in the SOA MNAME field), and to any servers listed in the ``also-notify`` option. - If ``master-only``, notifies are only sent for primary zones. If - ``explicit``, notifies are sent only to servers explicitly listed - using ``also-notify``. If ``no``, no notifies are sent. + If set to ``primary-only`` (or the older keyword ``master-only``), + notifies are only sent for primary zones. If set to ``explicit``, + notifies are sent only to servers explicitly listed using + ``also-notify``. If set to ``no``, no notifies are sent. The ``notify`` option may also be specified in the ``zone`` statement, in which case it overrides the ``options notify`` @@ -2240,7 +2246,7 @@ for details on how to specify IP address lists. global value is overridden. If not specified, the default is to process NOTIFY messages only from - the configured ``masters`` for the zone. ``allow-notify`` can be used + the configured ``primaries`` for the zone. ``allow-notify`` can be used to expand the list of permitted hosts, not to reduce it. ``allow-query`` @@ -2559,7 +2565,7 @@ options apply to zone transfers. than the default of 53. An optional TSIG key can also be specified with each address to cause the notify messages to be signed; this can be useful when sending notifies to multiple views. In place of - explicit addresses, one or more named ``masters`` lists can be used. + explicit addresses, one or more named ``primaries`` lists can be used. If an ``also-notify`` list is given in a ``zone`` statement, it overrides the ``options also-notify`` statement. When a @@ -2700,7 +2706,7 @@ options apply to zone transfers. ``notify-source`` ``notify-source`` determines which local source address, and optionally UDP port, is used to send NOTIFY messages. This - address must appear in the secondary server's ``masters`` zone clause or + address must appear in the secondary server's ``primaries`` zone clause or in an ``allow-notify`` clause. This statement sets the ``notify-source`` for all zones, but can be overridden on a per-zone or per-view basis by including a ``notify-source`` statement within @@ -5061,10 +5067,10 @@ it is an ``in-view`` configuration. Its acceptable values include: ``secondary`` A secondary zone is a replica of a primary zone. Type ``slave`` is a - synonym for ``secondary``. The ``masters`` list specifies one or more IP + synonym for ``secondary``. The ``primaries`` list specifies one or more IP addresses of primary servers that the secondary contacts to update - its copy of the zone. Masters list elements can - also be names of other masters lists. By default, + its copy of the zone. Primaires list elements can + also be names of other primaries lists. By default, transfers are made from port 53 on the servers; this can be changed for all servers by specifying a port number before the list of IP addresses, @@ -5139,7 +5145,7 @@ it is an ``in-view`` configuration. Its acceptable values include: Mirroring a zone other than root requires an explicit list of primary servers to be provided using the - ``masters`` option (see :ref:`masters_grammar` for details), and a + ``primaries`` option (see :ref:`primaries_grammar` for details), and a key-signing key (KSK) for the specified zone to be explicitly configured as a trust anchor. @@ -5231,7 +5237,7 @@ it is an ``in-view`` configuration. Its acceptable values include: Note that the redirect zone supports all possible types; it is not limited to A and AAAA records. - If a redirect zone is configured with a ``masters`` option, then it is + If a redirect zone is configured with a ``primaries`` option, then it is transferred in as if it were a secondary zone. Otherwise, it is loaded from a file as if it were a primary zone. @@ -5374,9 +5380,9 @@ Zone Options ``file`` This sets the zone's filename. In ``primary``, ``hint``, and ``redirect`` - zones which do not have ``masters`` defined, zone data is loaded from + zones which do not have ``primaries`` defined, zone data is loaded from this file. In ``secondary``, ``mirror``, ``stub``, and ``redirect`` zones - which do have ``masters`` defined, zone data is retrieved from + which do have ``primaries`` defined, zone data is retrieved from another server and saved in this file. This option is not applicable to other zone types. diff --git a/doc/misc/Makefile.am b/doc/misc/Makefile.am index 674c65247c8..32549892149 100644 --- a/doc/misc/Makefile.am +++ b/doc/misc/Makefile.am @@ -30,7 +30,7 @@ OPTIONS_FILES = \ dnssec-policy.grammar.rst \ key.grammar.rst \ logging.grammar.rst \ - masters.grammar.rst \ + primaries.grammar.rst \ options.grammar.rst \ server.grammar.rst \ statistics-channels.grammar.rst \ @@ -150,8 +150,8 @@ key.grammar.rst: options.active logging.grammar.rst: options.active $(AM_V_RST_GRAMMARS)$(PERL) $(srcdir)/rst-grammars.pl options.active logging > $@ -masters.grammar.rst: options.active - $(AM_V_RST_GRAMMARS)$(PERL) $(srcdir)/rst-grammars.pl options.active masters > $@ +primaries.grammar.rst: options.active + $(AM_V_RST_GRAMMARS)$(PERL) $(srcdir)/rst-grammars.pl options.active primaries > $@ options.grammar.rst: options.active $(AM_V_RST_GRAMMARS)$(PERL) $(srcdir)/rst-grammars.pl options.active options > $@ diff --git a/doc/misc/master.zoneopt b/doc/misc/master.zoneopt index 3ad1147bcf6..70f069f15c4 100644 --- a/doc/misc/master.zoneopt +++ b/doc/misc/master.zoneopt @@ -4,7 +4,7 @@ zone [ ] { allow-query-on { ; ... }; allow-transfer { ; ... }; allow-update { ; ... }; - also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; alt-transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; auto-dnssec ( allow | maintain | off ); diff --git a/doc/misc/master.zoneopt.rst b/doc/misc/master.zoneopt.rst index bc26c5f5dc7..df3a1ce9109 100644 --- a/doc/misc/master.zoneopt.rst +++ b/doc/misc/master.zoneopt.rst @@ -6,7 +6,7 @@ allow-query-on { ; ... }; allow-transfer { ; ... }; allow-update { ; ... }; - also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; alt-transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; auto-dnssec ( allow | maintain | off ); diff --git a/doc/misc/masters.grammar.rst b/doc/misc/masters.grammar.rst deleted file mode 100644 index 45b83450f60..00000000000 --- a/doc/misc/masters.grammar.rst +++ /dev/null @@ -1,6 +0,0 @@ -:: - - masters [ port ] [ dscp - ] { ( | [ - port ] | [ port - ] ) [ key ]; ... }; diff --git a/doc/misc/mirror.zoneopt b/doc/misc/mirror.zoneopt index 1c916df0002..ada8ae7438f 100644 --- a/doc/misc/mirror.zoneopt +++ b/doc/misc/mirror.zoneopt @@ -5,7 +5,7 @@ zone [ ] { allow-query-on { ; ... }; allow-transfer { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; alt-transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; check-names ( fail | warn | ignore ); @@ -15,7 +15,7 @@ zone [ ] { journal ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-ixfr-ratio ( unlimited | ); max-journal-size ( default | unlimited | ); max-records ; @@ -32,6 +32,7 @@ zone [ ] { notify-delay ; notify-source ( | * ) [ port ( | * ) ] [ dscp ]; notify-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; request-expire ; request-ixfr ; transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; diff --git a/doc/misc/mirror.zoneopt.rst b/doc/misc/mirror.zoneopt.rst index 01e86349cc3..9e229e006bf 100644 --- a/doc/misc/mirror.zoneopt.rst +++ b/doc/misc/mirror.zoneopt.rst @@ -7,7 +7,7 @@ allow-query-on { ; ... }; allow-transfer { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; alt-transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; check-names ( fail | warn | ignore ); @@ -17,7 +17,7 @@ journal ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-ixfr-ratio ( unlimited | ); max-journal-size ( default | unlimited | ); max-records ; @@ -34,6 +34,7 @@ notify-delay ; notify-source ( | * ) [ port ( | * ) ] [ dscp ]; notify-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; request-expire ; request-ixfr ; transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; diff --git a/doc/misc/options b/doc/misc/options index 8bcf5858957..bf30d1f10c8 100644 --- a/doc/misc/options +++ b/doc/misc/options @@ -69,8 +69,8 @@ managed-keys { ( static-key ; ... }; // may occur multiple times, deprecated masters [ port ] [ dscp - ] { ( | [ - port ] | [ port + ] { ( | + [ port ] | [ port ] ) [ key ]; ... }; // may occur multiple times options { @@ -90,7 +90,7 @@ options { allow-update { ; ... }; allow-update-forwarding { ; ... }; allow-v6-synthesis { ; ... }; // obsolete - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -108,7 +108,7 @@ options { blackhole { ; ... }; cache-file ; catalog-zones { zone [ default-masters [ port ] - [ dscp ] { ( | [ port + [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... } ] [ zone-directory ] [ in-memory ] [ min-update-interval ]; ... }; @@ -166,13 +166,16 @@ options { dnssec-secure-to-insecure ; dnssec-update-mode ( maintain | no-resign ); dnssec-validation ( yes | no | auto ); - dnstap { ( all | auth | client | forwarder | resolver | update ) [ - ( query | response ) ]; ... }; - dnstap-identity ( | none | hostname ); - dnstap-output ( file | unix ) [ size ( unlimited | - ) ] [ versions ( unlimited | ) ] [ suffix ( - increment | timestamp ) ]; - dnstap-version ( | none ); + dnstap { ( all | auth | client | forwarder | + resolver | update ) [ ( query | response ) ]; + ... }; // not configured + dnstap-identity ( | none | + hostname ); // not configured + dnstap-output ( file | unix ) [ + size ( unlimited | ) ] [ versions ( + unlimited | ) ] [ suffix ( increment + | timestamp ) ]; // not configured + dnstap-version ( | none ); // not configured dscp ; dual-stack-servers [ port ] { ( [ port ] [ dscp ] | [ port @@ -196,13 +199,13 @@ options { forward ( first | only ); forwarders [ port ] [ dscp ] { ( | ) [ port ] [ dscp ]; ... }; - fstrm-set-buffer-hint ; - fstrm-set-flush-timeout ; - fstrm-set-input-queue-size ; - fstrm-set-output-notify-threshold ; - fstrm-set-output-queue-model ( mpsc | spsc ); - fstrm-set-output-queue-size ; - fstrm-set-reopen-interval ; + fstrm-set-buffer-hint ; // not configured + fstrm-set-flush-timeout ; // not configured + fstrm-set-input-queue-size ; // not configured + fstrm-set-output-notify-threshold ; // not configured + fstrm-set-output-queue-model ( mpsc | spsc ); // not configured + fstrm-set-output-queue-size ; // not configured + fstrm-set-reopen-interval ; // not configured geoip-directory ( | none ); geoip-use-ecs ; // obsolete glue-cache ; @@ -411,6 +414,11 @@ options { plugin ( query ) [ { } ]; // may occur multiple times +primaries [ port ] [ dscp + ] { ( | + [ port ] | [ port + ] ) [ key ]; ... }; // may occur multiple times + server { bogus ; edns ; @@ -479,7 +487,7 @@ view [ ] { allow-update { ; ... }; allow-update-forwarding { ; ... }; allow-v6-synthesis { ; ... }; // obsolete - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -491,7 +499,7 @@ view [ ] { auto-dnssec ( allow | maintain | off ); cache-file ; catalog-zones { zone [ default-masters [ port ] - [ dscp ] { ( | [ port + [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... } ] [ zone-directory ] [ in-memory ] [ min-update-interval ]; ... }; @@ -547,8 +555,9 @@ view [ ] { dnssec-secure-to-insecure ; dnssec-update-mode ( maintain | no-resign ); dnssec-validation ( yes | no | auto ); - dnstap { ( all | auth | client | forwarder | resolver | update ) [ - ( query | response ) ]; ... }; + dnstap { ( all | auth | client | forwarder | + resolver | update ) [ ( query | response ) ]; + ... }; // not configured dual-stack-servers [ port ] { ( [ port ] [ dscp ] | [ port ] [ dscp ] | [ port @@ -775,7 +784,7 @@ view [ ] { allow-update { ; ... }; allow-update-forwarding { ; ... }; also-notify [ port ] [ dscp ] { ( - | [ port ] | + | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( @@ -818,9 +827,10 @@ view [ ] { maintain-ixfr-base ; // ancient masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( - | [ port ] | [ - port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( + | [ port ] | + [ port ] ) [ key ]; + ... }; max-ixfr-log-size ( default | unlimited | ); // ancient max-ixfr-ratio ( unlimited | ); @@ -844,6 +854,10 @@ view [ ] { | * ) ] [ dscp ]; notify-to-soa ; nsec3-test-zone ; // test only + primaries [ port ] [ dscp ] { ( + | [ port ] | + [ port ] ) [ key ]; + ... }; pubkey ; // ancient request-expire ; @@ -883,7 +897,7 @@ zone [ ] { allow-transfer { ; ... }; allow-update { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -924,7 +938,7 @@ zone [ ] { maintain-ixfr-base ; // ancient masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-ixfr-log-size ( default | unlimited | ); // ancient @@ -949,6 +963,9 @@ zone [ ] { [ dscp ]; notify-to-soa ; nsec3-test-zone ; // test only + primaries [ port ] [ dscp ] { ( | + [ port ] | [ port + ] ) [ key ]; ... }; pubkey ; // ancient request-expire ; request-ixfr ; diff --git a/doc/misc/options.active b/doc/misc/options.active index 40dec8ba636..0be7cffd74d 100644 --- a/doc/misc/options.active +++ b/doc/misc/options.active @@ -67,8 +67,8 @@ managed-keys { ( static-key ; ... }; // may occur multiple times, deprecated masters [ port ] [ dscp - ] { ( | [ - port ] | [ port + ] { ( | + [ port ] | [ port ] ) [ key ]; ... }; // may occur multiple times options { @@ -83,7 +83,7 @@ options { allow-transfer { ; ... }; allow-update { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -101,7 +101,7 @@ options { blackhole { ; ... }; cache-file ; catalog-zones { zone [ default-masters [ port ] - [ dscp ] { ( | [ port + [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... } ] [ zone-directory ] [ in-memory ] [ min-update-interval ]; ... }; @@ -368,6 +368,11 @@ options { plugin ( query ) [ { } ]; // may occur multiple times +primaries [ port ] [ dscp + ] { ( | + [ port ] | [ port + ] ) [ key ]; ... }; // may occur multiple times + server { bogus ; edns ; @@ -429,7 +434,7 @@ view [ ] { allow-transfer { ; ... }; allow-update { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -441,7 +446,7 @@ view [ ] { auto-dnssec ( allow | maintain | off ); cache-file ; catalog-zones { zone [ default-masters [ port ] - [ dscp ] { ( | [ port + [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... } ] [ zone-directory ] [ in-memory ] [ min-update-interval ]; ... }; @@ -701,7 +706,7 @@ view [ ] { allow-update { ; ... }; allow-update-forwarding { ; ... }; also-notify [ port ] [ dscp ] { ( - | [ port ] | + | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( @@ -741,9 +746,10 @@ view [ ] { key-directory ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( - | [ port ] | [ - port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( + | [ port ] | + [ port ] ) [ key ]; + ... }; max-ixfr-ratio ( unlimited | ); max-journal-size ( default | unlimited | ); max-records ; @@ -764,6 +770,10 @@ view [ ] { notify-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; notify-to-soa ; + primaries [ port ] [ dscp ] { ( + | [ port ] | + [ port ] ) [ key ]; + ... }; request-expire ; request-ixfr ; serial-update-method ( date | increment | unixtime ); @@ -801,7 +811,7 @@ zone [ ] { allow-transfer { ; ... }; allow-update { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -839,7 +849,7 @@ zone [ ] { key-directory ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-ixfr-ratio ( unlimited | ); @@ -862,6 +872,9 @@ zone [ ] { notify-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; notify-to-soa ; + primaries [ port ] [ dscp ] { ( | + [ port ] | [ port + ] ) [ key ]; ... }; request-expire ; request-ixfr ; serial-update-method ( date | increment | unixtime ); diff --git a/doc/misc/options.grammar.rst b/doc/misc/options.grammar.rst index f7d9657b754..f5cb236cfb0 100644 --- a/doc/misc/options.grammar.rst +++ b/doc/misc/options.grammar.rst @@ -12,7 +12,7 @@ allow-transfer { ; ... }; allow-update { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) @@ -30,7 +30,7 @@ blackhole { ; ... }; cache-file ; catalog-zones { zone [ default-masters [ port ] - [ dscp ] { ( | [ port + [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... } ] [ zone-directory ] [ in-memory ] [ min-update-interval ]; ... }; diff --git a/doc/misc/primaries.grammar.rst b/doc/misc/primaries.grammar.rst new file mode 100644 index 00000000000..2f6ba537d86 --- /dev/null +++ b/doc/misc/primaries.grammar.rst @@ -0,0 +1,6 @@ +:: + + primaries [ port ] [ dscp + ] { ( | + [ port ] | [ port + ] ) [ key ]; ... }; diff --git a/doc/misc/redirect.zoneopt b/doc/misc/redirect.zoneopt index 2a755de9d84..40df0e5b9c9 100644 --- a/doc/misc/redirect.zoneopt +++ b/doc/misc/redirect.zoneopt @@ -6,8 +6,9 @@ zone [ ] { file ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-records ; max-zone-ttl ( unlimited | ); + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; zone-statistics ( full | terse | none | ); }; diff --git a/doc/misc/redirect.zoneopt.rst b/doc/misc/redirect.zoneopt.rst index 2ec9046f0fd..5a08a22e3c2 100644 --- a/doc/misc/redirect.zoneopt.rst +++ b/doc/misc/redirect.zoneopt.rst @@ -8,8 +8,9 @@ file ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-records ; max-zone-ttl ( unlimited | ); + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; zone-statistics ( full | terse | none | ); }; diff --git a/doc/misc/slave.zoneopt b/doc/misc/slave.zoneopt index c8ce2e23fe1..6a3deee91d9 100644 --- a/doc/misc/slave.zoneopt +++ b/doc/misc/slave.zoneopt @@ -5,7 +5,7 @@ zone [ ] { allow-query-on { ; ... }; allow-transfer { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; alt-transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; auto-dnssec ( allow | maintain | off ); @@ -27,7 +27,7 @@ zone [ ] { key-directory ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-ixfr-ratio ( unlimited | ); max-journal-size ( default | unlimited | ); max-records ; @@ -45,6 +45,7 @@ zone [ ] { notify-source ( | * ) [ port ( | * ) ] [ dscp ]; notify-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; notify-to-soa ; + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; request-expire ; request-ixfr ; sig-signing-nodes ; diff --git a/doc/misc/slave.zoneopt.rst b/doc/misc/slave.zoneopt.rst index 08395efe442..b5a0b02ae98 100644 --- a/doc/misc/slave.zoneopt.rst +++ b/doc/misc/slave.zoneopt.rst @@ -7,7 +7,7 @@ allow-query-on { ; ... }; allow-transfer { ; ... }; allow-update-forwarding { ; ... }; - also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + also-notify [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; alt-transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; alt-transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; auto-dnssec ( allow | maintain | off ); @@ -29,7 +29,7 @@ key-directory ; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-ixfr-ratio ( unlimited | ); max-journal-size ( default | unlimited | ); max-records ; @@ -47,6 +47,7 @@ notify-source ( | * ) [ port ( | * ) ] [ dscp ]; notify-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; notify-to-soa ; + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; request-expire ; request-ixfr ; sig-signing-nodes ; diff --git a/doc/misc/stub.zoneopt b/doc/misc/stub.zoneopt index b18b1029122..d7c583bbb10 100644 --- a/doc/misc/stub.zoneopt +++ b/doc/misc/stub.zoneopt @@ -11,7 +11,7 @@ zone [ ] { forwarders [ port ] [ dscp ] { ( | ) [ port ] [ dscp ]; ... }; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-records ; max-refresh-time ; max-retry-time ; @@ -20,6 +20,7 @@ zone [ ] { min-refresh-time ; min-retry-time ; multi-master ; + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; use-alt-transfer-source ; diff --git a/doc/misc/stub.zoneopt.rst b/doc/misc/stub.zoneopt.rst index 7357617f256..02e7cc8d356 100644 --- a/doc/misc/stub.zoneopt.rst +++ b/doc/misc/stub.zoneopt.rst @@ -13,7 +13,7 @@ forwarders [ port ] [ dscp ] { ( | ) [ port ] [ dscp ]; ... }; masterfile-format ( map | raw | text ); masterfile-style ( full | relative ); - masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; + masters [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; max-records ; max-refresh-time ; max-retry-time ; @@ -22,6 +22,7 @@ min-refresh-time ; min-retry-time ; multi-master ; + primaries [ port ] [ dscp ] { ( | [ port ] | [ port ] ) [ key ]; ... }; transfer-source ( | * ) [ port ( | * ) ] [ dscp ]; transfer-source-v6 ( | * ) [ port ( | * ) ] [ dscp ]; use-alt-transfer-source ; diff --git a/lib/bind9/check.c b/lib/bind9/check.c index 5ae21284996..eb9e5a105cb 100644 --- a/lib/bind9/check.c +++ b/lib/bind9/check.c @@ -1665,17 +1665,21 @@ check_options(const cfg_obj_t *options, isc_log_t *logctx, isc_mem_t *mctx, } static isc_result_t -get_masters_def(const cfg_obj_t *cctx, const char *name, - const cfg_obj_t **ret) { +get_primaries_def(const cfg_obj_t *cctx, const char *name, + const cfg_obj_t **ret) { isc_result_t result; - const cfg_obj_t *masters = NULL; + const cfg_obj_t *primaries = NULL; const cfg_listelt_t *elt; - result = cfg_map_get(cctx, "masters", &masters); + result = cfg_map_get(cctx, "primaries", &primaries); + if (result != ISC_R_SUCCESS) { + result = cfg_map_get(cctx, "masters", &primaries); + } if (result != ISC_R_SUCCESS) { return (result); } - for (elt = cfg_list_first(masters); elt != NULL; + + for (elt = cfg_list_first(primaries); elt != NULL; elt = cfg_list_next(elt)) { const cfg_obj_t *list; const char *listname; @@ -1692,8 +1696,8 @@ get_masters_def(const cfg_obj_t *cctx, const char *name, } static isc_result_t -validate_masters(const cfg_obj_t *obj, const cfg_obj_t *config, - uint32_t *countp, isc_log_t *logctx, isc_mem_t *mctx) { +validate_primaries(const cfg_obj_t *obj, const cfg_obj_t *config, + uint32_t *countp, isc_log_t *logctx, isc_mem_t *mctx) { isc_result_t result = ISC_R_SUCCESS; isc_result_t tresult; uint32_t count = 0; @@ -1720,8 +1724,8 @@ resume: const cfg_obj_t *addr; const cfg_obj_t *key; - addr = cfg_tuple_get(cfg_listelt_value(element), "masterselemen" - "t"); + addr = cfg_tuple_get(cfg_listelt_value(element), + "primarieselement"); key = cfg_tuple_get(cfg_listelt_value(element), "key"); if (cfg_obj_issockaddr(addr)) { @@ -1743,13 +1747,13 @@ resume: if (tresult == ISC_R_EXISTS) { continue; } - tresult = get_masters_def(config, listname, &obj); + tresult = get_primaries_def(config, listname, &obj); if (tresult != ISC_R_SUCCESS) { if (result == ISC_R_SUCCESS) { result = tresult; } cfg_obj_log(addr, logctx, ISC_LOG_ERROR, - "unable to find masters list '%s'", + "unable to find primaries list '%s'", listname); continue; } @@ -2476,8 +2480,8 @@ check_zoneconf(const cfg_obj_t *zconfig, const cfg_obj_t *voptions, } if (tresult == ISC_R_SUCCESS && donotify) { uint32_t count; - tresult = validate_masters(obj, config, &count, logctx, - mctx); + tresult = validate_primaries(obj, config, &count, + logctx, mctx); if (tresult != ISC_R_SUCCESS && result == ISC_R_SUCCESS) { result = tresult; @@ -2486,7 +2490,7 @@ check_zoneconf(const cfg_obj_t *zconfig, const cfg_obj_t *voptions, } /* - * Slave, mirror, and stub zones must have a "masters" field, with one + * Slave, mirror, and stub zones must have a "primaries" field, with one * exception: when mirroring the root zone, a default, built-in master * server list is used in the absence of one explicitly specified. */ @@ -2495,22 +2499,39 @@ check_zoneconf(const cfg_obj_t *zconfig, const cfg_obj_t *voptions, !dns_name_equal(zname, dns_rootname))) { obj = NULL; - if (cfg_map_get(zoptions, "masters", &obj) != ISC_R_SUCCESS) { + (void)cfg_map_get(zoptions, "primaries", &obj); + if (obj == NULL) { + /* If "primaries" was unset, check for "masters" */ + (void)cfg_map_get(zoptions, "masters", &obj); + } else { + const cfg_obj_t *obj2 = NULL; + + /* ...bug if it was set, "masters" must not be. */ + (void)cfg_map_get(zoptions, "masters", &obj2); + if (obj2 != NULL) { + cfg_obj_log(obj, logctx, ISC_LOG_ERROR, + "'primaries' and 'masters' cannot " + "both be used in the same zone"); + result = ISC_R_FAILURE; + } + } + if (obj == NULL) { cfg_obj_log(zoptions, logctx, ISC_LOG_ERROR, - "zone '%s': missing 'masters' entry", + "zone '%s': missing 'primaries' entry", znamestr); result = ISC_R_FAILURE; } else { uint32_t count; - tresult = validate_masters(obj, config, &count, logctx, - mctx); + tresult = validate_primaries(obj, config, &count, + logctx, mctx); if (tresult != ISC_R_SUCCESS && result == ISC_R_SUCCESS) { result = tresult; } if (tresult == ISC_R_SUCCESS && count == 0) { cfg_obj_log(zoptions, logctx, ISC_LOG_ERROR, - "zone '%s': empty 'masters' entry", + "zone '%s': " + "empty 'primaries' entry", znamestr); result = ISC_R_FAILURE; } diff --git a/lib/dns/include/dns/zone.h b/lib/dns/include/dns/zone.h index 093e4675986..42437f11e7f 100644 --- a/lib/dns/include/dns/zone.h +++ b/lib/dns/include/dns/zone.h @@ -58,10 +58,11 @@ typedef enum { DNS_ZONEOPT_NOMERGE = 1 << 2, /*%< don't merge journal */ DNS_ZONEOPT_CHECKNS = 1 << 3, /*%< check if NS's are addresses */ DNS_ZONEOPT_FATALNS = 1 << 4, /*%< DNS_ZONEOPT_CHECKNS is fatal */ - DNS_ZONEOPT_MULTIMASTER = 1 << 5, /*%< this zone has multiple masters */ - DNS_ZONEOPT_USEALTXFRSRC = 1 << 6, /*%< use alternate transfer sources - */ - DNS_ZONEOPT_CHECKNAMES = 1 << 7, /*%< check-names */ + DNS_ZONEOPT_MULTIMASTER = 1 << 5, /*%< this zone has multiple + primaries */ + DNS_ZONEOPT_USEALTXFRSRC = 1 << 6, /*%< use alternate transfer sources + */ + DNS_ZONEOPT_CHECKNAMES = 1 << 7, /*%< check-names */ DNS_ZONEOPT_CHECKNAMESFAIL = 1 << 8, /*%< fatal check-name failures */ DNS_ZONEOPT_CHECKWILDCARD = 1 << 9, /*%< check for internal wildcards */ DNS_ZONEOPT_CHECKMX = 1 << 10, /*%< check-mx */ @@ -623,24 +624,24 @@ dns_zone_maintenance(dns_zone_t *zone); */ isc_result_t -dns_zone_setmasters(dns_zone_t *zone, const isc_sockaddr_t *masters, - uint32_t count); +dns_zone_setprimaries(dns_zone_t *zone, const isc_sockaddr_t *primaries, + uint32_t count); isc_result_t -dns_zone_setmasterswithkeys(dns_zone_t *zone, const isc_sockaddr_t *masters, - dns_name_t **keynames, uint32_t count); +dns_zone_setprimarieswithkeys(dns_zone_t *zone, const isc_sockaddr_t *primaries, + dns_name_t **keynames, uint32_t count); /*%< * Set the list of master servers for the zone. * * Require: *\li 'zone' to be a valid zone. - *\li 'masters' array of isc_sockaddr_t with port set or NULL. - *\li 'count' the number of masters. + *\li 'primaries' array of isc_sockaddr_t with port set or NULL. + *\li 'count' the number of primaries. *\li 'keynames' array of dns_name_t's for tsig keys or NULL. * - * \li dns_zone_setmasters() is just a wrapper to setmasterswithkeys(), + * \li dns_zone_setprimaries() is just a wrapper to setprimarieswithkeys(), * passing NULL in the keynames field. * - * \li If 'masters' is NULL then 'count' must be zero. + * \li If 'primaries' is NULL then 'count' must be zero. * * Returns: *\li #ISC_R_SUCCESS @@ -1550,7 +1551,7 @@ dns_zone_forwardupdate(dns_zone_t *zone, dns_message_t *msg, dns_updatecallback_t callback, void *callback_arg); /*%< * Forward 'msg' to each master in turn until we get an answer or we - * have exhausted the list of masters. 'callback' will be called with + * have exhausted the list of primaries. 'callback' will be called with * ISC_R_SUCCESS if we get an answer and the returned message will be * passed as 'answer_message', otherwise a non ISC_R_SUCCESS result code * will be passed and answer_message will be NULL. The callback function diff --git a/lib/dns/win32/libdns.def.in b/lib/dns/win32/libdns.def.in index 5f5505288d1..c9fca3355b8 100644 --- a/lib/dns/win32/libdns.def.in +++ b/lib/dns/win32/libdns.def.in @@ -1311,8 +1311,6 @@ dns_zone_setkasp dns_zone_setkeydirectory dns_zone_setkeyopt dns_zone_setkeyvalidityinterval -dns_zone_setmasters -dns_zone_setmasterswithkeys dns_zone_setmaxrecords dns_zone_setmaxrefreshtime dns_zone_setmaxretrytime @@ -1332,6 +1330,8 @@ dns_zone_setnotifytype dns_zone_setnsec3param dns_zone_setoption dns_zone_setorigin +dns_zone_setprimaries +dns_zone_setprimarieswithkeys dns_zone_setprivatetype dns_zone_setqueryacl dns_zone_setqueryonacl diff --git a/lib/dns/zone.c b/lib/dns/zone.c index ead79a8f76a..2cd966d28b7 100644 --- a/lib/dns/zone.c +++ b/lib/dns/zone.c @@ -474,7 +474,7 @@ typedef enum { DNS_ZONEFLG_DIFFONRELOAD = 0x00000800U, /*%< generate a journal diff on * reload */ DNS_ZONEFLG_NOMASTERS = 0x00001000U, /*%< an attempt to refresh a - * zone with no masters + * zone with no primaries * occurred */ DNS_ZONEFLG_LOADING = 0x00002000U, /*%< load from disk in progress*/ DNS_ZONEFLG_HAVETIMERS = 0x00004000U, /*%< timer values have been set @@ -1281,7 +1281,7 @@ zone_free(dns_zone_t *zone) { dns_catz_catzs_detach(&zone->catzs); } zone_freedbargs(zone); - RUNTIME_CHECK(dns_zone_setmasterswithkeys(zone, NULL, NULL, 0) == + RUNTIME_CHECK(dns_zone_setprimarieswithkeys(zone, NULL, NULL, 0) == ISC_R_SUCCESS); RUNTIME_CHECK(dns_zone_setalsonotify(zone, NULL, 0) == ISC_R_SUCCESS); zone->check_names = dns_severity_ignore; @@ -6234,17 +6234,17 @@ unlock: } isc_result_t -dns_zone_setmasters(dns_zone_t *zone, const isc_sockaddr_t *masters, - uint32_t count) { +dns_zone_setprimaries(dns_zone_t *zone, const isc_sockaddr_t *masters, + uint32_t count) { isc_result_t result; - result = dns_zone_setmasterswithkeys(zone, masters, NULL, count); + result = dns_zone_setprimarieswithkeys(zone, masters, NULL, count); return (result); } isc_result_t -dns_zone_setmasterswithkeys(dns_zone_t *zone, const isc_sockaddr_t *masters, - dns_name_t **keynames, uint32_t count) { +dns_zone_setprimarieswithkeys(dns_zone_t *zone, const isc_sockaddr_t *masters, + dns_name_t **keynames, uint32_t count) { isc_result_t result = ISC_R_SUCCESS; isc_sockaddr_t *newaddrs = NULL; isc_dscp_t *newdscps = NULL; @@ -6260,9 +6260,9 @@ dns_zone_setmasterswithkeys(dns_zone_t *zone, const isc_sockaddr_t *masters, LOCK_ZONE(zone); /* - * The refresh code assumes that 'masters' wouldn't change under it. + * The refresh code assumes that 'primaries' wouldn't change under it. * If it will change then kill off any current refresh in progress - * and update the masters info. If it won't change then we can just + * and update the primaries info. If it won't change then we can just * unlock and exit. */ if (count != zone->masterscnt || @@ -6305,7 +6305,7 @@ dns_zone_setmasterswithkeys(dns_zone_t *zone, const isc_sockaddr_t *masters, } /* - * Now set up the masters and masterkey lists + * Now set up the primaries and primary key lists */ result = set_addrkeylist(count, masters, &newaddrs, NULL, &newdscps, keynames, &newnames, zone->mctx); @@ -10937,7 +10937,8 @@ zone_maintenance(dns_zone_t *zone) { } /* - * Slaves send notifies before backing up to disk, masters after. + * Secondaries send notifies before backing up to disk, + * primaries after. */ if ((zone->type == dns_zone_slave || zone->type == dns_zone_mirror) && (DNS_ZONE_FLAG(zone, DNS_ZONEFLG_NEEDNOTIFY) || @@ -11198,7 +11199,7 @@ dns_zone_refresh(dns_zone_t *zone) { DNS_ZONE_SETFLAG(zone, DNS_ZONEFLG_NOMASTERS); if ((oldflags & DNS_ZONEFLG_NOMASTERS) == 0) { dns_zone_log(zone, ISC_LOG_ERROR, - "cannot refresh: no masters"); + "cannot refresh: no primaries"); } goto unlock; } @@ -12781,7 +12782,7 @@ next_master: !DNS_ZONE_FLAG(zone, DNS_ZONEFLG_USEALTXFRSRC)) { /* - * Did we get a good answer from all the masters? + * Did we get a good answer from all the primaries? */ for (j = 0; j < zone->masterscnt; j++) { if (!zone->mastersok[j]) { @@ -13305,7 +13306,7 @@ next_master: !DNS_ZONE_FLAG(zone, DNS_ZONEFLG_USEALTXFRSRC)) { /* - * Did we get a good answer from all the masters? + * Did we get a good answer from all the primaries? */ for (j = 0; j < zone->masterscnt; j++) { if (!zone->mastersok[j]) { @@ -17267,7 +17268,7 @@ forward_callback(isc_task_t *task, isc_event_t *event) { break; } - /* These should not occur if the masters/zone are valid. */ + /* These should not occur if the primaries/zone are valid. */ case dns_rcode_notzone: case dns_rcode_notauth: { char rcode[128]; diff --git a/lib/isccfg/namedconf.c b/lib/isccfg/namedconf.c index 55e16c997b1..c7906fb42c2 100644 --- a/lib/isccfg/namedconf.c +++ b/lib/isccfg/namedconf.c @@ -99,7 +99,7 @@ static cfg_type_t cfg_type_logging; static cfg_type_t cfg_type_logseverity; static cfg_type_t cfg_type_logsuffix; static cfg_type_t cfg_type_logversions; -static cfg_type_t cfg_type_masterselement; +static cfg_type_t cfg_type_primarieselement; static cfg_type_t cfg_type_maxduration; static cfg_type_t cfg_type_minimal; static cfg_type_t cfg_type_nameportiplist; @@ -167,8 +167,8 @@ static cfg_type_t cfg_type_acl = { "acl", cfg_parse_tuple, cfg_print_tuple, cfg_doc_tuple, &cfg_rep_tuple, acl_fields }; -/*% masters */ -static cfg_tuplefielddef_t masters_fields[] = { +/*% primaries */ +static cfg_tuplefielddef_t primaries_fields[] = { { "name", &cfg_type_astring, 0 }, { "port", &cfg_type_optional_port, 0 }, { "dscp", &cfg_type_optional_dscp, 0 }, @@ -176,19 +176,19 @@ static cfg_tuplefielddef_t masters_fields[] = { { NULL, NULL, 0 } }; -static cfg_type_t cfg_type_masters = { "masters", cfg_parse_tuple, - cfg_print_tuple, cfg_doc_tuple, - &cfg_rep_tuple, masters_fields }; +static cfg_type_t cfg_type_primaries = { "primaries", cfg_parse_tuple, + cfg_print_tuple, cfg_doc_tuple, + &cfg_rep_tuple, primaries_fields }; /*% * "sockaddrkeylist", a list of socket addresses with optional keys - * and an optional default port, as used in the masters option. + * and an optional default port, as used in the primaries option. * E.g., - * "port 1234 { mymasters; 10.0.0.1 key foo; 1::2 port 69; }" + * "port 1234 { myprimaries; 10.0.0.1 key foo; 1::2 port 69; }" */ static cfg_tuplefielddef_t namesockaddrkey_fields[] = { - { "masterselement", &cfg_type_masterselement, 0 }, + { "primarieselement", &cfg_type_primarieselement, 0 }, { "key", &cfg_type_optional_keyref, 0 }, { NULL, NULL, 0 }, }; @@ -1068,8 +1068,9 @@ static cfg_clausedef_t namedconf_clauses[] = { { "logging", &cfg_type_logging, 0 }, { "lwres", &cfg_type_bracketed_text, CFG_CLAUSEFLAG_MULTI | CFG_CLAUSEFLAG_OBSOLETE }, - { "masters", &cfg_type_masters, CFG_CLAUSEFLAG_MULTI }, + { "masters", &cfg_type_primaries, CFG_CLAUSEFLAG_MULTI }, { "options", &cfg_type_options, 0 }, + { "primaries", &cfg_type_primaries, CFG_CLAUSEFLAG_MULTI }, { "statistics-channels", &cfg_type_statschannels, CFG_CLAUSEFLAG_MULTI }, { "view", &cfg_type_view, CFG_CLAUSEFLAG_MULTI }, @@ -2275,6 +2276,9 @@ static cfg_clausedef_t zone_only_clauses[] = { { "masters", &cfg_type_namesockaddrkeylist, CFG_ZONE_SLAVE | CFG_ZONE_MIRROR | CFG_ZONE_STUB | CFG_ZONE_REDIRECT }, + { "primaries", &cfg_type_namesockaddrkeylist, + CFG_ZONE_SLAVE | CFG_ZONE_MIRROR | CFG_ZONE_STUB | + CFG_ZONE_REDIRECT }, { "pubkey", &cfg_type_pubkey, CFG_CLAUSEFLAG_ANCIENT }, { "server-addresses", &cfg_type_bracketed_netaddrlist, CFG_ZONE_STATICSTUB }, @@ -3621,14 +3625,14 @@ static cfg_type_t cfg_type_nameportiplist = { }; /*% - * masters element. + * primaries element. */ static void -doc_masterselement(cfg_printer_t *pctx, const cfg_type_t *type) { +doc_primarieselement(cfg_printer_t *pctx, const cfg_type_t *type) { UNUSED(type); cfg_print_cstr(pctx, "( "); - cfg_print_cstr(pctx, ""); + cfg_print_cstr(pctx, ""); cfg_print_cstr(pctx, " | "); cfg_print_cstr(pctx, ""); cfg_print_cstr(pctx, " "); @@ -3641,8 +3645,8 @@ doc_masterselement(cfg_printer_t *pctx, const cfg_type_t *type) { } static isc_result_t -parse_masterselement(cfg_parser_t *pctx, const cfg_type_t *type, - cfg_obj_t **ret) { +parse_primarieselement(cfg_parser_t *pctx, const cfg_type_t *type, + cfg_obj_t **ret) { isc_result_t result; cfg_obj_t *obj = NULL; UNUSED(type); @@ -3660,7 +3664,7 @@ parse_masterselement(cfg_parser_t *pctx, const cfg_type_t *type, } } else { cfg_parser_error(pctx, CFG_LOG_NEAR, - "expected IP address or masters name"); + "expected IP address or primaries list name"); return (ISC_R_UNEXPECTEDTOKEN); } cleanup: @@ -3668,12 +3672,12 @@ cleanup: return (result); } -static cfg_type_t cfg_type_masterselement = { "masters_element", - parse_masterselement, - NULL, - doc_masterselement, - NULL, - NULL }; +static cfg_type_t cfg_type_primarieselement = { "primaries_element", + parse_primarieselement, + NULL, + doc_primarieselement, + NULL, + NULL }; static int cmp_clause(const void *ap, const void *bp) {