xref: /netbsd-src/external/bsd/unbound/dist/pythonmod/doc/modules/config.rst (revision 91f7d55fb697b5e0475da4718fa34c3a3ebeac85)
1Configuration interface
2=======================
3
4Currently passed to Python module in init(module_id, cfg).
5
6config_file
7--------------------
8
9.. class:: config_file
10
11   This class provides these data attributes:
12
13   .. attribute:: verbosity
14
15      Verbosity level as specified in the config file.
16
17   .. attribute:: stat_interval
18
19      Statistics interval (in seconds).
20
21   .. attribute:: stat_cumulative
22
23      If false, statistics values are reset after printing them.
24
25   .. attribute:: stat_extended
26
27      If true, the statistics are kept in greater detail.
28
29   .. attribute:: num_threads
30
31      Number of threads to create.
32
33   .. attribute:: port
34
35      Port on which queries are answered.
36
37   .. attribute:: do_ip4
38
39      Do ip4 query support.
40
41   .. attribute:: do_ip6
42
43      Do ip6 query support.
44
45   .. attribute:: do_udp
46
47      Do udp query support.
48
49   .. attribute:: do_tcp
50
51      Do tcp query support.
52
53   .. attribute:: outgoing_num_ports
54
55      Outgoing port range number of ports (per thread).
56
57   .. attribute:: outgoing_num_tcp
58
59      Number of outgoing tcp buffers per (per thread).
60
61   .. attribute:: incoming_num_tcp
62
63      Number of incoming tcp buffers per (per thread).
64
65   .. attribute:: outgoing_avail_ports
66
67      Allowed udp port numbers, array with 0 if not allowed.
68
69   .. attribute:: msg_buffer_size
70
71      Number of bytes buffer size for DNS messages.
72
73   .. attribute:: msg_cache_size
74
75      Size of the message cache.
76
77   .. attribute:: msg_cache_slabs
78
79      Slabs in the message cache.
80
81   .. attribute:: num_queries_per_thread
82
83      Number of queries every thread can service.
84
85   .. attribute:: jostle_time
86
87      Number of msec to wait before items can be jostled out.
88
89   .. attribute:: rrset_cache_size
90
91      Size of the rrset cache.
92
93   .. attribute:: rrset_cache_slabs
94
95      Slabs in the rrset cache.
96
97   .. attribute:: host_ttl
98
99      Host cache ttl in seconds.
100
101   .. attribute:: lame_ttl
102
103      Host is lame for a zone ttl, in seconds.
104
105   .. attribute:: infra_cache_slabs
106
107      Number of slabs in the infra host cache.
108
109   .. attribute:: infra_cache_numhosts
110
111      Max number of hosts in the infra cache.
112
113   .. attribute:: infra_cache_lame_size
114
115      Max size of lame zones per host in the infra cache.
116
117   .. attribute:: target_fetch_policy
118
119      The target fetch policy for the iterator.
120
121   .. attribute:: if_automatic
122
123      Automatic interface for incoming messages. Uses ipv6 remapping,
124      and recvmsg/sendmsg ancillary data to detect interfaces, boolean.
125
126   .. attribute:: num_ifs
127
128      Number of interfaces to open. If 0 default all interfaces.
129
130   .. attribute:: ifs
131
132      List of interface description strings (IP addresses).
133
134   .. attribute:: num_out_ifs
135
136      Number of outgoing interfaces to open.
137      If 0 default all interfaces.
138
139   .. attribute:: out_ifs
140
141      List of outgoing interface description strings (IP addresses).
142
143   .. attribute:: root_hints
144
145      The root hints.
146
147   .. attribute:: stubs
148
149      The stub definitions, linked list.
150
151   .. attribute:: forwards
152
153      The forward zone definitions, linked list.
154
155   .. attribute:: donotqueryaddrs
156
157      List of donotquery addresses, linked list.
158
159   .. attribute:: acls
160
161      List of access control entries, linked list.
162
163   .. attribute:: donotquery_localhost
164
165      Use default localhost donotqueryaddr entries.
166
167   .. attribute:: harden_short_bufsize
168
169      Harden against very small edns buffer sizes.
170
171   .. attribute:: harden_large_queries
172
173      Harden against very large query sizes.
174
175   .. attribute:: harden_glue
176
177      Harden against spoofed glue (out of zone data).
178
179   .. attribute:: harden_dnssec_stripped
180
181      Harden against receiving no DNSSEC data for trust anchor.
182
183   .. attribute:: harden_referral_path
184
185      Harden the referral path, query for NS,A,AAAA and validate.
186
187   .. attribute:: use_caps_bits_for_id
188
189      Use 0x20 bits in query as random ID bits.
190
191   .. attribute:: private_address
192
193      Strip away these private addrs from answers, no DNS Rebinding.
194
195   .. attribute:: private_domain
196
197      Allow domain (and subdomains) to use private address space.
198
199   .. attribute:: unwanted_threshold
200
201      What threshold for unwanted action.
202
203   .. attribute:: chrootdir
204
205      Chrootdir, if not "" or chroot will be done.
206
207   .. attribute:: username
208
209      Username to change to, if not "".
210
211   .. attribute:: directory
212
213      Working directory.
214
215   .. attribute:: logfile
216
217      Filename to log to.
218
219   .. attribute:: pidfile
220
221      Pidfile to write pid to.
222
223   .. attribute:: use_syslog
224
225      Should log messages be sent to syslogd.
226
227   .. attribute:: hide_identity
228
229      Do not report identity (id.server, hostname.bind).
230
231   .. attribute:: hide_version
232
233      Do not report version (version.server, version.bind).
234
235   .. attribute:: identity
236
237      Identity, hostname is returned if "".
238
239   .. attribute:: version
240
241      Version, package version returned if "".
242
243   .. attribute:: module_conf
244
245      The module configuration string.
246
247   .. attribute:: trust_anchor_file_list
248
249      Files with trusted DS and DNSKEYs in zonefile format, list.
250
251   .. attribute:: trust_anchor_list
252
253      List of trustanchor keys, linked list.
254
255   .. attribute:: trusted_keys_file_list
256
257      Files with trusted DNSKEYs in named.conf format, list.
258
259   .. attribute:: max_ttl
260
261      The number of seconds maximal TTL used for RRsets and messages.
262
263   .. attribute:: val_date_override
264
265      If not 0, this value is the validation date for RRSIGs.
266
267   .. attribute:: bogus_ttl
268
269      This value sets the number of seconds before revalidating bogus.
270
271   .. attribute:: val_clean_additional
272
273      Should validator clean additional section for secure msgs.
274
275   .. attribute:: val_permissive_mode
276
277      Should validator allow bogus messages to go through.
278
279   .. attribute:: val_nsec3_key_iterations
280
281      Nsec3 maximum iterations per key size, string.
282
283   .. attribute:: key_cache_size
284
285      Size of the key cache.
286
287   .. attribute:: key_cache_slabs
288
289      Slabs in the key cache.
290
291   .. attribute:: neg_cache_size
292
293      Size of the neg cache.
294
295
296   .. attribute:: local_zones
297
298      Local zones config.
299
300   .. attribute:: local_zones_nodefault
301
302      Local zones nodefault list.
303
304   .. attribute:: local_data
305
306      Local data RRs configured.
307
308   .. attribute:: remote_control_enable
309
310      Remote control section. enable toggle.
311
312   .. attribute:: control_ifs
313
314      The interfaces the remote control should listen on.
315
316   .. attribute:: control_port
317
318      Port number for the control port.
319
320   .. attribute:: server_key_file
321
322      Private key file for server.
323
324   .. attribute:: server_cert_file
325
326      Certificate file for server.
327
328   .. attribute:: control_key_file
329
330      Private key file for unbound-control.
331
332   .. attribute:: control_cert_file
333
334      Certificate file for unbound-control.
335
336   .. attribute:: do_daemonize
337
338      Daemonize, i.e. fork into the background.
339
340   .. attribute:: python_script
341
342      Linked list of Python script files.
343      Deprecated; `mod_env['script']` should be used instead.
344