1276612Sdes#
2276612Sdes# Example configuration file.
3276612Sdes#
4296415Sdes# See unbound.conf(5) man page, version 1.5.8.
5276612Sdes#
6276612Sdes# this is a comment.
7276612Sdes
8276612Sdes#Use this to include other text into the file.
9276612Sdes#include: "otherfile.conf"
10276612Sdes
11292206Sdes# The server clause sets the main parameters.
12276612Sdesserver:
13276612Sdes	# whitespace is not necessary, but looks cleaner.
14276612Sdes
15276612Sdes	# verbosity number, 0 is least verbose. 1 is default.
16276612Sdes	verbosity: 1
17276612Sdes
18276612Sdes	# print statistics to the log (for every thread) every N seconds.
19276612Sdes	# Set to "" or 0 to disable. Default is disabled.
20276612Sdes	# statistics-interval: 0
21276612Sdes
22276612Sdes	# enable cumulative statistics, without clearing them after printing.
23276612Sdes	# statistics-cumulative: no
24276612Sdes
25276612Sdes	# enable extended statistics (query types, answer codes, status)
26276612Sdes	# printed from unbound-control. default off, because of speed.
27276612Sdes	# extended-statistics: no
28276612Sdes
29276612Sdes	# number of threads to create. 1 disables threading.
30276612Sdes	# num-threads: 1
31276612Sdes
32276612Sdes	# specify the interfaces to answer queries from by ip-address.
33276612Sdes	# The default is to listen to localhost (127.0.0.1 and ::1).
34276612Sdes	# specify 0.0.0.0 and ::0 to bind to all available interfaces.
35276612Sdes	# specify every interface[@port] on a new 'interface:' labelled line.
36276612Sdes	# The listen interfaces are not changed on reload, only on restart.
37276612Sdes	# interface: 192.0.2.153
38276612Sdes	# interface: 192.0.2.154
39276612Sdes	# interface: 192.0.2.154@5003
40276612Sdes	# interface: 2001:DB8::5
41276612Sdes
42276612Sdes	# enable this feature to copy the source address of queries to reply.
43292206Sdes	# Socket options are not supported on all platforms. experimental.
44276612Sdes	# interface-automatic: no
45276612Sdes
46276612Sdes	# port to answer queries from
47276612Sdes	# port: 53
48276612Sdes
49276612Sdes	# specify the interfaces to send outgoing queries to authoritative
50276612Sdes	# server from by ip-address. If none, the default (all) interface
51276612Sdes	# is used. Specify every interface on a 'outgoing-interface:' line.
52276612Sdes	# outgoing-interface: 192.0.2.153
53276612Sdes	# outgoing-interface: 2001:DB8::5
54276612Sdes	# outgoing-interface: 2001:DB8::6
55276612Sdes
56276612Sdes	# number of ports to allocate per thread, determines the size of the
57276612Sdes	# port range that can be open simultaneously.  About double the
58276612Sdes	# num-queries-per-thread, or, use as many as the OS will allow you.
59276612Sdes	# outgoing-range: 4096
60276612Sdes
61276612Sdes	# permit unbound to use this port number or port range for
62276612Sdes	# making outgoing queries, using an outgoing interface.
63276612Sdes	# outgoing-port-permit: 32768
64276612Sdes
65276612Sdes	# deny unbound the use this of port number or port range for
66276612Sdes	# making outgoing queries, using an outgoing interface.
67276612Sdes	# Use this to make sure unbound does not grab a UDP port that some
68276612Sdes	# other server on this computer needs. The default is to avoid
69276612Sdes	# IANA-assigned port numbers.
70276612Sdes	# If multiple outgoing-port-permit and outgoing-port-avoid options
71276612Sdes	# are present, they are processed in order.
72276612Sdes	# outgoing-port-avoid: "3200-3208"
73276612Sdes
74276612Sdes	# number of outgoing simultaneous tcp buffers to hold per thread.
75276612Sdes	# outgoing-num-tcp: 10
76276612Sdes
77276612Sdes	# number of incoming simultaneous tcp buffers to hold per thread.
78276612Sdes	# incoming-num-tcp: 10
79276612Sdes
80276612Sdes	# buffer size for UDP port 53 incoming (SO_RCVBUF socket option).
81276612Sdes	# 0 is system default.  Use 4m to catch query spikes for busy servers.
82276612Sdes	# so-rcvbuf: 0
83276612Sdes
84276612Sdes	# buffer size for UDP port 53 outgoing (SO_SNDBUF socket option).
85276612Sdes	# 0 is system default.  Use 4m to handle spikes on very busy servers.
86276612Sdes	# so-sndbuf: 0
87292206Sdes
88276612Sdes	# use SO_REUSEPORT to distribute queries over threads.
89276612Sdes	# so-reuseport: no
90292206Sdes
91287917Sdes	# use IP_TRANSPARENT so the interface: addresses can be non-local
92287917Sdes	# and you can config non-existing IPs that are going to work later on
93296415Sdes	# (uses IP_BINDANY on FreeBSD).
94287917Sdes	# ip-transparent: no
95276612Sdes
96276612Sdes	# EDNS reassembly buffer to advertise to UDP peers (the actual buffer
97276612Sdes	# is set with msg-buffer-size). 1480 can solve fragmentation (timeouts).
98276612Sdes	# edns-buffer-size: 4096
99276612Sdes
100276612Sdes	# Maximum UDP response size (not applied to TCP response).
101276612Sdes	# Suggested values are 512 to 4096. Default is 4096. 65536 disables it.
102276612Sdes	# max-udp-size: 4096
103276612Sdes
104276612Sdes	# buffer size for handling DNS data. No messages larger than this
105276612Sdes	# size can be sent or received, by UDP or TCP. In bytes.
106276612Sdes	# msg-buffer-size: 65552
107276612Sdes
108276612Sdes	# the amount of memory to use for the message cache.
109292206Sdes	# plain value in bytes or you can append k, m or G. default is "4Mb".
110276612Sdes	# msg-cache-size: 4m
111276612Sdes
112276612Sdes	# the number of slabs to use for the message cache.
113276612Sdes	# the number of slabs must be a power of 2.
114276612Sdes	# more slabs reduce lock contention, but fragment memory usage.
115276612Sdes	# msg-cache-slabs: 4
116276612Sdes
117276612Sdes	# the number of queries that a thread gets to service.
118276612Sdes	# num-queries-per-thread: 1024
119276612Sdes
120276612Sdes	# if very busy, 50% queries run to completion, 50% get timeout in msec
121276612Sdes	# jostle-timeout: 200
122292206Sdes
123276612Sdes	# msec to wait before close of port on timeout UDP. 0 disables.
124276612Sdes	# delay-close: 0
125276612Sdes
126276612Sdes	# the amount of memory to use for the RRset cache.
127292206Sdes	# plain value in bytes or you can append k, m or G. default is "4Mb".
128276612Sdes	# rrset-cache-size: 4m
129276612Sdes
130276612Sdes	# the number of slabs to use for the RRset cache.
131276612Sdes	# the number of slabs must be a power of 2.
132276612Sdes	# more slabs reduce lock contention, but fragment memory usage.
133276612Sdes	# rrset-cache-slabs: 4
134276612Sdes
135276612Sdes	# the time to live (TTL) value lower bound, in seconds. Default 0.
136276612Sdes	# If more than an hour could easily give trouble due to stale data.
137276612Sdes	# cache-min-ttl: 0
138276612Sdes
139276612Sdes	# the time to live (TTL) value cap for RRsets and messages in the
140276612Sdes	# cache. Items are not cached for longer. In seconds.
141276612Sdes	# cache-max-ttl: 86400
142276612Sdes
143287917Sdes	# the time to live (TTL) value cap for negative responses in the cache
144287917Sdes	# cache-max-negative-ttl: 3600
145287917Sdes
146276612Sdes	# the time to live (TTL) value for cached roundtrip times, lameness and
147276612Sdes	# EDNS version information for hosts. In seconds.
148276612Sdes	# infra-host-ttl: 900
149292206Sdes
150282089Sdes	# minimum wait time for responses, increase if uplink is long. In msec.
151282089Sdes	# infra-cache-min-rtt: 50
152276612Sdes
153276612Sdes	# the number of slabs to use for the Infrastructure cache.
154276612Sdes	# the number of slabs must be a power of 2.
155276612Sdes	# more slabs reduce lock contention, but fragment memory usage.
156276612Sdes	# infra-cache-slabs: 4
157276612Sdes
158276612Sdes	# the maximum number of hosts that are cached (roundtrip, EDNS, lame).
159276612Sdes	# infra-cache-numhosts: 10000
160276612Sdes
161276612Sdes	# Enable IPv4, "yes" or "no".
162276612Sdes	# do-ip4: yes
163276612Sdes
164276612Sdes	# Enable IPv6, "yes" or "no".
165276612Sdes	# do-ip6: yes
166276612Sdes
167276612Sdes	# Enable UDP, "yes" or "no".
168276612Sdes	# do-udp: yes
169276612Sdes
170276612Sdes	# Enable TCP, "yes" or "no".
171276612Sdes	# do-tcp: yes
172276612Sdes
173276612Sdes	# upstream connections use TCP only (and no UDP), "yes" or "no"
174276612Sdes	# useful for tunneling scenarios, default no.
175276612Sdes	# tcp-upstream: no
176276612Sdes
177296415Sdes	# Maximum segment size (MSS) of TCP socket on which the server
178296415Sdes	# responds to queries. Default is 0, system default MSS.
179296415Sdes	# tcp-mss: 0
180296415Sdes
181296415Sdes	# Maximum segment size (MSS) of TCP socket for outgoing queries.
182296415Sdes	# Default is 0, system default MSS.
183296415Sdes	# outgoing-tcp-mss: 0
184296415Sdes
185276612Sdes	# Detach from the terminal, run in background, "yes" or "no".
186276612Sdes	# do-daemonize: yes
187276612Sdes
188276612Sdes	# control which clients are allowed to make (recursive) queries
189276612Sdes	# to this server. Specify classless netblocks with /size and action.
190276612Sdes	# By default everything is refused, except for localhost.
191276612Sdes	# Choose deny (drop message), refuse (polite error reply),
192276612Sdes	# allow (recursive ok), allow_snoop (recursive and nonrecursive ok)
193276612Sdes	# deny_non_local (drop queries unless can be answered from local-data)
194276612Sdes	# refuse_non_local (like deny_non_local but polite error reply).
195276612Sdes	# access-control: 0.0.0.0/0 refuse
196276612Sdes	# access-control: 127.0.0.0/8 allow
197276612Sdes	# access-control: ::0/0 refuse
198276612Sdes	# access-control: ::1 allow
199276612Sdes	# access-control: ::ffff:127.0.0.1 allow
200276612Sdes
201276612Sdes	# if given, a chroot(2) is done to the given directory.
202276612Sdes	# i.e. you can chroot to the working directory, for example,
203276612Sdes	# for extra security, but make sure all files are in that directory.
204276612Sdes	#
205276612Sdes	# If chroot is enabled, you should pass the configfile (from the
206276612Sdes	# commandline) as a full path from the original root. After the
207292206Sdes	# chroot has been performed the now defunct portion of the config
208292206Sdes	# file path is removed to be able to reread the config after a reload.
209276612Sdes	#
210276612Sdes	# All other file paths (working dir, logfile, roothints, and
211276612Sdes	# key files) can be specified in several ways:
212276612Sdes	# 	o as an absolute path relative to the new root.
213276612Sdes	# 	o as a relative path to the working directory.
214276612Sdes	# 	o as an absolute path relative to the original root.
215276612Sdes	# In the last case the path is adjusted to remove the unused portion.
216276612Sdes	#
217292206Sdes	# The pid file can be absolute and outside of the chroot, it is
218276612Sdes	# written just prior to performing the chroot and dropping permissions.
219276612Sdes	#
220276612Sdes	# Additionally, unbound may need to access /dev/random (for entropy).
221276612Sdes	# How to do this is specific to your OS.
222276612Sdes	#
223276612Sdes	# If you give "" no chroot is performed. The path must not end in a /.
224276612Sdes	# chroot: "/var/unbound"
225276612Sdes
226276612Sdes	# if given, user privileges are dropped (after binding port),
227276612Sdes	# and the given username is assumed. Default is user "unbound".
228276612Sdes	# If you give "" no privileges are dropped.
229276612Sdes	# username: "unbound"
230276612Sdes
231292206Sdes	# the working directory. The relative files in this config are
232276612Sdes	# relative to this directory. If you give "" the working directory
233276612Sdes	# is not changed.
234276612Sdes	# directory: "/var/unbound"
235276612Sdes
236292206Sdes	# the log file, "" means log to stderr.
237276612Sdes	# Use of this option sets use-syslog to "no".
238276612Sdes	# logfile: ""
239276612Sdes
240292206Sdes	# Log to syslog(3) if yes. The log facility LOG_DAEMON is used to
241276612Sdes	# log to, with identity "unbound". If yes, it overrides the logfile.
242292206Sdes	# use-syslog: yes
243276612Sdes
244276612Sdes	# print UTC timestamp in ascii to logfile, default is epoch in seconds.
245276612Sdes	# log-time-ascii: no
246292206Sdes
247276612Sdes	# print one line with time, IP, name, type, class for every query.
248276612Sdes	# log-queries: no
249276612Sdes
250276612Sdes	# the pid file. Can be an absolute path outside of chroot/work dir.
251276612Sdes	# pidfile: "/var/unbound/unbound.pid"
252276612Sdes
253276612Sdes	# file to read root hints from.
254292206Sdes	# get one from https://www.internic.net/domain/named.cache
255276612Sdes	# root-hints: ""
256276612Sdes
257276612Sdes	# enable to not answer id.server and hostname.bind queries.
258276612Sdes	# hide-identity: no
259276612Sdes
260276612Sdes	# enable to not answer version.server and version.bind queries.
261276612Sdes	# hide-version: no
262276612Sdes
263276612Sdes	# the identity to report. Leave "" or default to return hostname.
264276612Sdes	# identity: ""
265276612Sdes
266276612Sdes	# the version to report. Leave "" or default to return package version.
267276612Sdes	# version: ""
268276612Sdes
269276612Sdes	# the target fetch policy.
270292206Sdes	# series of integers describing the policy per dependency depth.
271292206Sdes	# The number of values in the list determines the maximum dependency
272276612Sdes	# depth the recursor will pursue before giving up. Each integer means:
273276612Sdes	# 	-1 : fetch all targets opportunistically,
274276612Sdes	# 	0: fetch on demand,
275276612Sdes	#	positive value: fetch that many targets opportunistically.
276276612Sdes	# Enclose the list of numbers between quotes ("").
277276612Sdes	# target-fetch-policy: "3 2 1 0 0"
278276612Sdes
279292206Sdes	# Harden against very small EDNS buffer sizes.
280276612Sdes	# harden-short-bufsize: no
281276612Sdes
282276612Sdes	# Harden against unseemly large queries.
283276612Sdes	# harden-large-queries: no
284276612Sdes
285292206Sdes	# Harden against out of zone rrsets, to avoid spoofing attempts.
286276612Sdes	# harden-glue: yes
287276612Sdes
288276612Sdes	# Harden against receiving dnssec-stripped data. If you turn it
289292206Sdes	# off, failing to validate dnskey data for a trustanchor will
290276612Sdes	# trigger insecure mode for that zone (like without a trustanchor).
291276612Sdes	# Default on, which insists on dnssec data for trust-anchored zones.
292276612Sdes	# harden-dnssec-stripped: yes
293276612Sdes
294276612Sdes	# Harden against queries that fall under dnssec-signed nxdomain names.
295276612Sdes	# harden-below-nxdomain: no
296276612Sdes
297276612Sdes        # Harden the referral path by performing additional queries for
298276612Sdes	# infrastructure data.  Validates the replies (if possible).
299292206Sdes	# Default off, because the lookups burden the server.  Experimental
300276612Sdes	# implementation of draft-wijngaards-dnsext-resolver-side-mitigation.
301276612Sdes	# harden-referral-path: no
302276612Sdes
303287917Sdes	# Harden against algorithm downgrade when multiple algorithms are
304287917Sdes	# advertised in the DS record.  If no, allows the weakest algorithm
305287917Sdes	# to validate the zone.
306289063Sdes	# harden-algo-downgrade: no
307287917Sdes
308292206Sdes	# Sent minimum amount of information to upstream servers to enhance
309292206Sdes	# privacy. Only sent minimum required labels of the QNAME and set QTYPE
310292206Sdes	# to NS when possible.
311292206Sdes	# qname-minimisation: no
312292206Sdes
313276612Sdes	# Use 0x20-encoded random bits in the query to foil spoof attempts.
314276612Sdes	# This feature is an experimental implementation of draft dns-0x20.
315276612Sdes	# use-caps-for-id: no
316292206Sdes
317287917Sdes	# Domains (and domains in them) without support for dns-0x20 and
318287917Sdes	# the fallback fails because they keep sending different answers.
319287917Sdes	# caps-whitelist: "licdn.com"
320276612Sdes
321292206Sdes	# Enforce privacy of these addresses. Strips them away from answers.
322292206Sdes	# It may cause DNSSEC validation to additionally mark it as bogus.
323292206Sdes	# Protects against 'DNS Rebinding' (uses browser as network proxy).
324292206Sdes	# Only 'private-domain' and 'local-data' names are allowed to have
325276612Sdes	# these private addresses. No default.
326276612Sdes	# private-address: 10.0.0.0/8
327276612Sdes	# private-address: 172.16.0.0/12
328276612Sdes	# private-address: 192.168.0.0/16
329276612Sdes	# private-address: 169.254.0.0/16
330276612Sdes	# private-address: fd00::/8
331276612Sdes	# private-address: fe80::/10
332292206Sdes	# private-address: ::ffff:0:0/96
333276612Sdes
334276612Sdes	# Allow the domain (and its subdomains) to contain private addresses.
335276612Sdes	# local-data statements are allowed to contain private addresses too.
336276612Sdes	# private-domain: "example.com"
337276612Sdes
338276612Sdes	# If nonzero, unwanted replies are not only reported in statistics,
339276612Sdes	# but also a running total is kept per thread. If it reaches the
340276612Sdes	# threshold, a warning is printed and a defensive action is taken,
341276612Sdes	# the cache is cleared to flush potential poison out of it.
342276612Sdes	# A suggested value is 10000000, the default is 0 (turned off).
343276612Sdes	# unwanted-reply-threshold: 0
344276612Sdes
345276612Sdes	# Do not query the following addresses. No DNS queries are sent there.
346276612Sdes	# List one address per entry. List classless netblocks with /size,
347276612Sdes	# do-not-query-address: 127.0.0.1/8
348276612Sdes	# do-not-query-address: ::1
349276612Sdes
350276612Sdes	# if yes, the above default do-not-query-address entries are present.
351276612Sdes	# if no, localhost can be queried (for testing and debugging).
352276612Sdes	# do-not-query-localhost: yes
353276612Sdes
354276612Sdes	# if yes, perform prefetching of almost expired message cache entries.
355276612Sdes	# prefetch: no
356276612Sdes
357276612Sdes	# if yes, perform key lookups adjacent to normal lookups.
358276612Sdes	# prefetch-key: no
359276612Sdes
360276612Sdes	# if yes, Unbound rotates RRSet order in response.
361276612Sdes	# rrset-roundrobin: no
362276612Sdes
363276612Sdes	# if yes, Unbound doesn't insert authority/additional sections
364276612Sdes	# into response messages when those sections are not required.
365276612Sdes	# minimal-responses: no
366276612Sdes
367276612Sdes	# module configuration of the server. A string with identifiers
368276612Sdes	# separated by spaces. Syntax: "[dns64] [validator] iterator"
369276612Sdes	# module-config: "validator iterator"
370276612Sdes
371276612Sdes	# File with trusted keys, kept uptodate using RFC5011 probes,
372276612Sdes	# initial file like trust-anchor-file, then it stores metadata.
373276612Sdes	# Use several entries, one per domain name, to track multiple zones.
374276612Sdes	#
375276612Sdes	# If you want to perform DNSSEC validation, run unbound-anchor before
376276612Sdes	# you start unbound (i.e. in the system boot scripts).  And enable:
377276612Sdes	# Please note usage of unbound-anchor root anchor is at your own risk
378276612Sdes	# and under the terms of our LICENSE (see that file in the source).
379276612Sdes	# auto-trust-anchor-file: "/var/unbound/root.key"
380276612Sdes
381276612Sdes	# File with DLV trusted keys. Same format as trust-anchor-file.
382276612Sdes	# There can be only one DLV configured, it is trusted from root down.
383287917Sdes	# DLV is going to be decommissioned.  Please do not use it any more.
384276612Sdes	# dlv-anchor-file: "dlv.isc.org.key"
385276612Sdes
386276612Sdes	# File with trusted keys for validation. Specify more than one file
387276612Sdes	# with several entries, one file per entry.
388276612Sdes	# Zone file format, with DS and DNSKEY entries.
389276612Sdes	# Note this gets out of date, use auto-trust-anchor-file please.
390276612Sdes	# trust-anchor-file: ""
391292206Sdes
392276612Sdes	# Trusted key for validation. DS or DNSKEY. specify the RR on a
393276612Sdes	# single line, surrounded by "". TTL is ignored. class is IN default.
394276612Sdes	# Note this gets out of date, use auto-trust-anchor-file please.
395276612Sdes	# (These examples are from August 2007 and may not be valid anymore).
396276612Sdes	# trust-anchor: "nlnetlabs.nl. DNSKEY 257 3 5 AQPzzTWMz8qSWIQlfRnPckx2BiVmkVN6LPupO3mbz7FhLSnm26n6iG9N Lby97Ji453aWZY3M5/xJBSOS2vWtco2t8C0+xeO1bc/d6ZTy32DHchpW 6rDH1vp86Ll+ha0tmwyy9QP7y2bVw5zSbFCrefk8qCUBgfHm9bHzMG1U BYtEIQ=="
397276612Sdes	# trust-anchor: "jelte.nlnetlabs.nl. DS 42860 5 1 14D739EB566D2B1A5E216A0BA4D17FA9B038BE4A"
398276612Sdes
399276612Sdes	# File with trusted keys for validation. Specify more than one file
400276612Sdes	# with several entries, one file per entry. Like trust-anchor-file
401292206Sdes	# but has a different file format. Format is BIND-9 style format,
402276612Sdes	# the trusted-keys { name flag proto algo "key"; }; clauses are read.
403276612Sdes	# you need external update procedures to track changes in keys.
404276612Sdes	# trusted-keys-file: ""
405276612Sdes
406276612Sdes	# Ignore chain of trust. Domain is treated as insecure.
407276612Sdes	# domain-insecure: "example.com"
408276612Sdes
409276612Sdes	# Override the date for validation with a specific fixed date.
410276612Sdes	# Do not set this unless you are debugging signature inception
411276612Sdes	# and expiration. "" or "0" turns the feature off. -1 ignores date.
412276612Sdes	# val-override-date: ""
413276612Sdes
414276612Sdes	# The time to live for bogus data, rrsets and messages. This avoids
415276612Sdes	# some of the revalidation, until the time interval expires. in secs.
416276612Sdes	# val-bogus-ttl: 60
417276612Sdes
418276612Sdes	# The signature inception and expiration dates are allowed to be off
419276612Sdes	# by 10% of the signature lifetime (expir-incep) from our local clock.
420276612Sdes	# This leeway is capped with a minimum and a maximum.  In seconds.
421276612Sdes	# val-sig-skew-min: 3600
422276612Sdes	# val-sig-skew-max: 86400
423276612Sdes
424276612Sdes	# Should additional section of secure message also be kept clean of
425276612Sdes	# unsecure data. Useful to shield the users of this validator from
426292206Sdes	# potential bogus data in the additional section. All unsigned data
427276612Sdes	# in the additional section is removed from secure messages.
428276612Sdes	# val-clean-additional: yes
429276612Sdes
430276612Sdes	# Turn permissive mode on to permit bogus messages. Thus, messages
431276612Sdes	# for which security checks failed will be returned to clients,
432276612Sdes	# instead of SERVFAIL. It still performs the security checks, which
433276612Sdes	# result in interesting log files and possibly the AD bit in
434276612Sdes	# replies if the message is found secure. The default is off.
435276612Sdes	# val-permissive-mode: no
436276612Sdes
437276612Sdes	# Ignore the CD flag in incoming queries and refuse them bogus data.
438276612Sdes	# Enable it if the only clients of unbound are legacy servers (w2008)
439276612Sdes	# that set CD but cannot validate themselves.
440276612Sdes	# ignore-cd-flag: no
441276612Sdes
442276612Sdes	# Have the validator log failed validations for your diagnosis.
443276612Sdes	# 0: off. 1: A line per failed user query. 2: With reason and bad IP.
444276612Sdes	# val-log-level: 0
445276612Sdes
446276612Sdes	# It is possible to configure NSEC3 maximum iteration counts per
447276612Sdes	# keysize. Keep this table very short, as linear search is done.
448276612Sdes	# A message with an NSEC3 with larger count is marked insecure.
449276612Sdes	# List in ascending order the keysize and count values.
450276612Sdes	# val-nsec3-keysize-iterations: "1024 150 2048 500 4096 2500"
451292206Sdes
452276612Sdes	# instruct the auto-trust-anchor-file probing to add anchors after ttl.
453276612Sdes	# add-holddown: 2592000 # 30 days
454276612Sdes
455276612Sdes	# instruct the auto-trust-anchor-file probing to del anchors after ttl.
456276612Sdes	# del-holddown: 2592000 # 30 days
457276612Sdes
458276612Sdes	# auto-trust-anchor-file probing removes missing anchors after ttl.
459276612Sdes	# If the value 0 is given, missing anchors are not removed.
460276612Sdes	# keep-missing: 31622400 # 366 days
461276612Sdes
462289063Sdes	# debug option that allows very small holddown times for key rollover
463289063Sdes	# permit-small-holddown: no
464289063Sdes
465276612Sdes	# the amount of memory to use for the key cache.
466292206Sdes	# plain value in bytes or you can append k, m or G. default is "4Mb".
467276612Sdes	# key-cache-size: 4m
468276612Sdes
469276612Sdes	# the number of slabs to use for the key cache.
470276612Sdes	# the number of slabs must be a power of 2.
471276612Sdes	# more slabs reduce lock contention, but fragment memory usage.
472276612Sdes	# key-cache-slabs: 4
473276612Sdes
474276612Sdes	# the amount of memory to use for the negative cache (used for DLV).
475292206Sdes	# plain value in bytes or you can append k, m or G. default is "1Mb".
476276612Sdes	# neg-cache-size: 1m
477282089Sdes
478276612Sdes	# By default, for a number of zones a small default 'nothing here'
479276612Sdes	# reply is built-in.  Query traffic is thus blocked.  If you
480276612Sdes	# wish to serve such zone you can unblock them by uncommenting one
481276612Sdes	# of the nodefault statements below.
482276612Sdes	# You may also have to use domain-insecure: zone to make DNSSEC work,
483276612Sdes	# unless you have your own trust anchors for this zone.
484276612Sdes	# local-zone: "localhost." nodefault
485276612Sdes	# local-zone: "127.in-addr.arpa." nodefault
486276612Sdes	# local-zone: "1.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa." nodefault
487296415Sdes	# local-zone: "onion." nodefault
488276612Sdes	# local-zone: "10.in-addr.arpa." nodefault
489276612Sdes	# local-zone: "16.172.in-addr.arpa." nodefault
490276612Sdes	# local-zone: "17.172.in-addr.arpa." nodefault
491276612Sdes	# local-zone: "18.172.in-addr.arpa." nodefault
492276612Sdes	# local-zone: "19.172.in-addr.arpa." nodefault
493276612Sdes	# local-zone: "20.172.in-addr.arpa." nodefault
494276612Sdes	# local-zone: "21.172.in-addr.arpa." nodefault
495276612Sdes	# local-zone: "22.172.in-addr.arpa." nodefault
496276612Sdes	# local-zone: "23.172.in-addr.arpa." nodefault
497276612Sdes	# local-zone: "24.172.in-addr.arpa." nodefault
498276612Sdes	# local-zone: "25.172.in-addr.arpa." nodefault
499276612Sdes	# local-zone: "26.172.in-addr.arpa." nodefault
500276612Sdes	# local-zone: "27.172.in-addr.arpa." nodefault
501276612Sdes	# local-zone: "28.172.in-addr.arpa." nodefault
502276612Sdes	# local-zone: "29.172.in-addr.arpa." nodefault
503276612Sdes	# local-zone: "30.172.in-addr.arpa." nodefault
504276612Sdes	# local-zone: "31.172.in-addr.arpa." nodefault
505276612Sdes	# local-zone: "168.192.in-addr.arpa." nodefault
506276612Sdes	# local-zone: "0.in-addr.arpa." nodefault
507276612Sdes	# local-zone: "254.169.in-addr.arpa." nodefault
508276612Sdes	# local-zone: "2.0.192.in-addr.arpa." nodefault
509276612Sdes	# local-zone: "100.51.198.in-addr.arpa." nodefault
510276612Sdes	# local-zone: "113.0.203.in-addr.arpa." nodefault
511276612Sdes	# local-zone: "255.255.255.255.in-addr.arpa." nodefault
512276612Sdes	# local-zone: "0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.0.ip6.arpa." nodefault
513276612Sdes	# local-zone: "d.f.ip6.arpa." nodefault
514276612Sdes	# local-zone: "8.e.f.ip6.arpa." nodefault
515276612Sdes	# local-zone: "9.e.f.ip6.arpa." nodefault
516276612Sdes	# local-zone: "a.e.f.ip6.arpa." nodefault
517276612Sdes	# local-zone: "b.e.f.ip6.arpa." nodefault
518276612Sdes	# local-zone: "8.b.d.0.1.0.0.2.ip6.arpa." nodefault
519276612Sdes	# And for 64.100.in-addr.arpa. to 127.100.in-addr.arpa.
520292206Sdes
521295535Sdes	# If unbound is running service for the local host then it is useful
522276612Sdes	# to perform lan-wide lookups to the upstream, and unblock the
523276612Sdes	# long list of local-zones above.  If this unbound is a dns server
524276612Sdes	# for a network of computers, disabled is better and stops information
525276612Sdes	# leakage of local lan information.
526276612Sdes	# unblock-lan-zones: no
527276612Sdes
528295535Sdes	# The insecure-lan-zones option disables validation for
529295535Sdes	# these zones, as if they were all listed as domain-insecure.
530295535Sdes	# insecure-lan-zones: no
531295535Sdes
532276612Sdes	# a number of locally served zones can be configured.
533276612Sdes	# 	local-zone: <zone> <type>
534276612Sdes	# 	local-data: "<resource record string>"
535292206Sdes	# o deny serves local data (if any), else, drops queries.
536276612Sdes	# o refuse serves local data (if any), else, replies with error.
537276612Sdes	# o static serves local data, else, nxdomain or nodata answer.
538276612Sdes	# o transparent gives local data, but resolves normally for other names
539276612Sdes	# o redirect serves the zone data for any subdomain in the zone.
540276612Sdes	# o nodefault can be used to normally resolve AS112 zones.
541276612Sdes	# o typetransparent resolves normally for other types and other names
542282089Sdes	# o inform resolves normally, but logs client IP address
543287917Sdes	# o inform_deny drops queries and logs client IP address
544276612Sdes	#
545276612Sdes	# defaults are localhost address, reverse for 127.0.0.1 and ::1
546276612Sdes	# and nxdomain for AS112 zones. If you configure one of these zones
547276612Sdes	# the default content is omitted, or you can omit it with 'nodefault'.
548292206Sdes	#
549276612Sdes	# If you configure local-data without specifying local-zone, by
550276612Sdes	# default a transparent local-zone is created for the data.
551276612Sdes	#
552276612Sdes	# You can add locally served data with
553276612Sdes	# local-zone: "local." static
554276612Sdes	# local-data: "mycomputer.local. IN A 192.0.2.51"
555276612Sdes	# local-data: 'mytext.local TXT "content of text record"'
556276612Sdes	#
557276612Sdes	# You can override certain queries with
558276612Sdes	# local-data: "adserver.example.com A 127.0.0.1"
559276612Sdes	#
560276612Sdes	# You can redirect a domain to a fixed address with
561276612Sdes	# (this makes example.com, www.example.com, etc, all go to 192.0.2.3)
562276612Sdes	# local-zone: "example.com" redirect
563276612Sdes	# local-data: "example.com A 192.0.2.3"
564276612Sdes	#
565276612Sdes	# Shorthand to make PTR records, "IPv4 name" or "IPv6 name".
566276612Sdes	# You can also add PTR records using local-data directly, but then
567276612Sdes	# you need to do the reverse notation yourself.
568276612Sdes	# local-data-ptr: "192.0.2.3 www.example.com"
569276612Sdes
570276612Sdes	# service clients over SSL (on the TCP sockets), with plain DNS inside
571276612Sdes	# the SSL stream.  Give the certificate to use and private key.
572276612Sdes	# default is "" (disabled).  requires restart to take effect.
573276612Sdes	# ssl-service-key: "path/to/privatekeyfile.key"
574276612Sdes	# ssl-service-pem: "path/to/publiccertfile.pem"
575292206Sdes	# ssl-port: 853
576276612Sdes
577276612Sdes	# request upstream over SSL (with plain DNS inside the SSL stream).
578276612Sdes	# Default is no.  Can be turned on and off with unbound-control.
579276612Sdes	# ssl-upstream: no
580276612Sdes
581276612Sdes	# DNS64 prefix. Must be specified when DNS64 is use.
582276612Sdes	# Enable dns64 in module-config.  Used to synthesize IPv6 from IPv4.
583276612Sdes	# dns64-prefix: 64:ff9b::0/96
584276612Sdes
585287917Sdes	# ratelimit for uncached, new queries, this limits recursion effort.
586287917Sdes	# ratelimiting is experimental, and may help against randomqueryflood.
587287917Sdes	# if 0(default) it is disabled, otherwise state qps allowed per zone.
588287917Sdes	# ratelimit: 0
589287917Sdes
590287917Sdes	# ratelimits are tracked in a cache, size in bytes of cache (or k,m).
591287917Sdes	# ratelimit-size: 4m
592287917Sdes	# ratelimit cache slabs, reduces lock contention if equal to cpucount.
593287917Sdes	# ratelimit-slabs: 4
594292206Sdes
595287917Sdes	# 0 blocks when ratelimited, otherwise let 1/xth traffic through
596287917Sdes	# ratelimit-factor: 10
597287917Sdes
598287917Sdes	# override the ratelimit for a specific domain name.
599287917Sdes	# give this setting multiple times to have multiple overrides.
600287917Sdes	# ratelimit-for-domain: example.com 1000
601287917Sdes	# override the ratelimits for all domains below a domain name
602287917Sdes	# can give this multiple times, the name closest to the zone is used.
603287917Sdes	# ratelimit-below-domain: example 1000
604287917Sdes
605276612Sdes# Python config section. To enable:
606276612Sdes# o use --with-pythonmodule to configure before compiling.
607276612Sdes# o list python in the module-config string (above) to enable.
608276612Sdes# o and give a python-script to run.
609276612Sdespython:
610276612Sdes	# Script file to load
611276612Sdes	# python-script: "/var/unbound/ubmodule-tst.py"
612276612Sdes
613292206Sdes# Remote control config section.
614276612Sdesremote-control:
615276612Sdes	# Enable remote control with unbound-control(8) here.
616276612Sdes	# set up the keys and certificates with unbound-control-setup.
617276612Sdes	# control-enable: no
618276612Sdes
619282089Sdes	# Set to no and use an absolute path as control-interface to use
620282089Sdes	# a unix local named pipe for unbound-control.
621282089Sdes	# control-use-cert: yes
622282089Sdes
623276612Sdes	# what interfaces are listened to for remote control.
624276612Sdes	# give 0.0.0.0 and ::0 to listen to all interfaces.
625276612Sdes	# control-interface: 127.0.0.1
626276612Sdes	# control-interface: ::1
627276612Sdes
628276612Sdes	# port number for remote control operations.
629276612Sdes	# control-port: 8953
630276612Sdes
631276612Sdes	# unbound server key file.
632276612Sdes	# server-key-file: "/var/unbound/unbound_server.key"
633276612Sdes
634276612Sdes	# unbound server certificate file.
635276612Sdes	# server-cert-file: "/var/unbound/unbound_server.pem"
636276612Sdes
637276612Sdes	# unbound-control key file.
638276612Sdes	# control-key-file: "/var/unbound/unbound_control.key"
639276612Sdes
640276612Sdes	# unbound-control certificate file.
641276612Sdes	# control-cert-file: "/var/unbound/unbound_control.pem"
642276612Sdes
643276612Sdes# Stub zones.
644292206Sdes# Create entries like below, to make all queries for 'example.com' and
645292206Sdes# 'example.org' go to the given list of nameservers. list zero or more
646292206Sdes# nameservers by hostname or by ipaddress. If you set stub-prime to yes,
647276612Sdes# the list is treated as priming hints (default is no).
648276612Sdes# With stub-first yes, it attempts without the stub if it fails.
649289063Sdes# Consider adding domain-insecure: name and local-zone: name nodefault
650289063Sdes# to the server: section if the stub is a locally served zone.
651276612Sdes# stub-zone:
652276612Sdes#	name: "example.com"
653276612Sdes#	stub-addr: 192.0.2.68
654276612Sdes#	stub-prime: no
655276612Sdes#	stub-first: no
656276612Sdes# stub-zone:
657276612Sdes#	name: "example.org"
658276612Sdes#	stub-host: ns.example.com.
659276612Sdes
660276612Sdes# Forward zones
661276612Sdes# Create entries like below, to make all queries for 'example.com' and
662276612Sdes# 'example.org' go to the given list of servers. These servers have to handle
663276612Sdes# recursion to other nameservers. List zero or more nameservers by hostname
664276612Sdes# or by ipaddress. Use an entry with name "." to forward all queries.
665276612Sdes# If you enable forward-first, it attempts without the forward if it fails.
666276612Sdes# forward-zone:
667276612Sdes# 	name: "example.com"
668276612Sdes# 	forward-addr: 192.0.2.68
669276612Sdes# 	forward-addr: 192.0.2.73@5355  # forward to port 5355.
670276612Sdes# 	forward-first: no
671276612Sdes# forward-zone:
672276612Sdes# 	name: "example.org"
673276612Sdes# 	forward-host: fwd.example.com
674