xref: /netbsd-src/external/mpl/bind/dist/bin/tests/system/allow-query/ns2/named40.conf.in (revision 924795e69c8bb3f17afd8fcbb799710cc1719dc4)
1/*
2 * Copyright (C) Internet Systems Consortium, Inc. ("ISC")
3 *
4 * SPDX-License-Identifier: MPL-2.0
5 *
6 * This Source Code Form is subject to the terms of the Mozilla Public
7 * License, v. 2.0.  If a copy of the MPL was not distributed with this
8 * file, you can obtain one at https://mozilla.org/MPL/2.0/.
9 *
10 * See the COPYRIGHT file distributed with this work for additional
11 * information regarding copyright ownership.
12 */
13
14acl accept { 10.53.0.2; };
15
16acl badaccept { 10.53.0.1; };
17
18key one {
19	algorithm hmac-md5;
20	secret "1234abcd8765";
21};
22
23key two {
24	algorithm hmac-md5;
25	secret "1234efgh8765";
26};
27
28options {
29	port @PORT@;
30	pid-file "named.pid";
31	listen-on { 10.53.0.2; };
32	listen-on-v6 { none; };
33	recursion no;
34};
35
36include "controls.conf";
37
38zone "." {
39	type hint;
40	file "../../common/root.hint";
41};
42
43zone "normal.example" {
44	type primary;
45	file "generic.db";
46};
47
48zone "any.example" {
49	type primary;
50	file "generic.db";
51	allow-query { any; };
52};
53
54zone "none.example" {
55	type primary;
56	file "generic.db";
57	allow-query { none; };
58};
59
60zone "addrallow.example" {
61	type primary;
62	file "generic.db";
63	allow-query { 10.53.0.2; };
64};
65
66zone "addrnotallow.example" {
67	type primary;
68	file "generic.db";
69	allow-query { 10.53.0.1; };
70};
71
72zone "addrdisallow.example" {
73	type primary;
74	file "generic.db";
75	allow-query { ! 10.53.0.2; };
76};
77
78zone "aclallow.example" {
79	type primary;
80	file "generic.db";
81	allow-query { accept; };
82};
83
84zone "aclnotallow.example" {
85	type primary;
86	file "generic.db";
87	allow-query { badaccept; };
88};
89
90zone "acldisallow.example" {
91	type primary;
92	file "generic.db";
93	allow-query { ! accept; };
94};
95
96/* Also usable for testing key not allowed */
97zone "keyallow.example" {
98	type primary;
99	file "generic.db";
100	allow-query { key one; };
101};
102
103zone "keydisallow.example" {
104	type primary;
105	file "generic.db";
106	allow-query { ! key one; };
107};
108