Add direct-A test
[exim.git] / test / dnszones-src / db.test.ex
1 ; This is a testing zone file for use when testing DNS handling in Exim. This
2 ; is a fake zone of no real use - hence no SOA record. The zone name is
3 ; test.ex. This file is passed through the substitution mechanism before being
4 ; used by the fakens auxiliary program. This inserts the actual IP addresses
5 ; of the local host into the zone.
6
7 ; NOTE (1): apart from ::1, IPv6 addresses must always have 8 components. Do
8 ; not abbreviate them by using the :: feature. Leading zeros in components may,
9 ; however, be omitted.
10
11 ; NOTE (2): the fakens program is very simple and assumes that the buffer into
12 ; which is puts the response is always going to be big enough. In other words,
13 ; the expectation is for just a few RRs for each query.
14
15 ; NOTE (3): the top-level networks for testing addresses are parameterized by
16 ; the use of V4NET and V6NET. These networks should be such that no real
17 ; host ever uses them.
18
19 test.ex. NS exim.test.ex.
20
21 test.ex. TXT "A TXT record for test.ex."
22 s/lash TXT "A TXT record for s/lash.test.ex."
23
24 cname CNAME test.ex.
25
26 ptr PTR data.for.ptr.test.ex.
27
28 ; Standard localhost handling
29
30 localhost A 127.0.0.1
31 localhost AAAA ::1
32
33 ; This name exists only if qualified; it is never automatically qualified
34
35 dontqualify A V4NET.255.255.254
36
37 ; A host with upper case letters in its canonical name
38
39 UpperCase A 127.0.0.1
40
41 ; A host with UTF-8 characters in its name
42
43 mx.π A V4NET.255.255.255
44
45 ; A non-standard name for localhost
46
47 thishost A 127.0.0.1
48
49 ; Something that gives both the IP and the loopback
50
51 thisloop A HOSTIPV4
52 A 127.0.0.1
53
54 ; Something that gives an unreachable IP and the loopback
55
56 badloop A V4NET.0.0.1
57 A 127.0.0.1
58
59 ; Another host with both A and AAAA records
60
61 46 A V4NET.0.0.4
62 AAAA V6NET:ffff:836f:0a00:000a:0800:200a:c031
63
64 ; And another
65
66 46b A V4NET.0.0.5
67 AAAA V6NET:ffff:836f:0a00:000a:0800:200a:c033
68
69 ; A working IPv4 address and a non-working IPv6 address, with different
70 ; names so they can have different MX values
71
72 46c AAAA V6NET:ffff:836f:0a00:000a:0800:200a:c033
73 46d A HOSTIPV4
74
75 ; A host with just a non-local IPv6 address
76
77 v6 AAAA V6NET:ffff:836f:0a00:000a:0800:200a:c032
78
79 ; Alias A and CNAME records for the local host, under the name "eximtesthost"
80 ; Make the A covered by DNSSEC and add a TLSA for it.
81
82 eximtesthost A HOSTIPV4
83 alias-eximtesthost CNAME eximtesthost.test.ex.
84
85 ; A bad CNAME
86
87 badcname CNAME rhubarb.test.ex.
88
89 ; Test a name containing an underscore
90
91 a_b A 99.99.99.99
92
93 ; The reverse registration for this name is an empty string
94
95 empty A V4NET.255.255.255
96
97 ; Some IPv6 stuff
98
99 eximtesthost.ipv6 AAAA HOSTIPV6
100 test2.ipv6 AAAA V6NET:2101:12:1:a00:20ff:fe86:a062
101 test3.ipv6 AAAA V6NET:1234:5:6:7:8:abc:0d
102
103 ; A case of forward and backward pointers disagreeing
104
105 badA A V4NET.99.99.99
106 badB A V4NET.99.99.98
107
108 ; A host with multiple names in different (sub) domains
109 ; These are intended to be within test.ex - absence of final dots is deliberate
110
111 x.gov.uk A V4NET.99.99.97
112 x.co.uk A V4NET.99.99.97
113
114 ; A host, the reverse lookup of whose IP address gives this name plus another
115 ; that does not forward resolve to the same address
116
117 oneback A V4NET.99.99.90
118 host1.masq A V4NET.90.90.90
119
120 ; Fake hosts are registered in the V4NET.0.0.0 subnet. In the past, the
121 ; 10.0.0.0/8 network was used; hence the names of the hosts.
122
123 ten-1 A V4NET.0.0.1
124 ten-2 A V4NET.0.0.2
125 ten-3 A V4NET.0.0.3
126 ten-3-alias A V4NET.0.0.3
127 ten-3xtra A V4NET.0.0.3
128 ten-4 A V4NET.0.0.4
129 ten-5 A V4NET.0.0.5
130 ten-6 A V4NET.0.0.6
131 ten-5-6 A V4NET.0.0.5
132 A V4NET.0.0.6
133
134 ten-99 A V4NET.0.0.99
135
136 black-1 A V4NET.11.12.13
137 black-2 A V4NET.11.12.14
138
139 myhost A V4NET.10.10.10
140 myhost2 A V4NET.10.10.10
141
142 other1 A V4NET.12.4.5
143 other2 A V4NET.12.3.1
144 A V4NET.12.3.2
145
146 other99 A V4NET.99.0.1
147
148 testsub.sub A V4NET.99.0.3
149
150 ; This one's real name really is recurse.test.ex.test.ex. It is done like
151 ; this for testing host widening, without getting tangled up in qualify issues.
152
153 recurse.test.ex A V4NET.99.0.2
154
155 ; -------- Testing RBL records -------
156
157 ; V4NET.11.12.13 is deliberately not reverse-registered
158
159 13.12.11.V4NET.rbl A 127.0.0.2
160 TXT "This is a test blacklisting message"
161 14.12.11.V4NET.rbl A 127.0.0.2
162 TXT "This is a test blacklisting message"
163 15.12.11.V4NET.rbl A 127.0.0.2
164 TXT "This is a very long blacklisting message, continuing for ages and ages and certainly being longer than 128 characters which was a previous limit on the length that Exim was prepared to handle."
165
166 14.12.11.V4NET.rbl2 A 127.0.0.2
167 TXT "This is a test blacklisting2 message"
168 16.12.11.V4NET.rbl2 A 127.0.0.2
169 TXT "This is a test blacklisting2 message"
170
171 14.12.11.V4NET.rbl3 A 127.0.0.2
172 TXT "This is a test blacklisting3 message"
173 15.12.11.V4NET.rbl3 A 127.0.0.3
174 TXT "This is a very long blacklisting message, continuing for ages and ages and certainly being longer than 128 characters which was a previous limit on the length that Exim was prepared to handle."
175
176 20.12.11.V4NET.rbl4 A 127.0.0.6
177 21.12.11.V4NET.rbl4 A 127.0.0.7
178 22.12.11.V4NET.rbl4 A 127.0.0.128
179 TXT "This is a test blacklisting4 message"
180
181 22.12.11.V4NET.rbl5 A 127.0.0.1
182 TXT "This is a test blacklisting5 message"
183
184 1.13.13.V4NET.rbl CNAME non-exist.test.ex.
185 2.13.13.V4NET.rbl A 127.0.0.1
186 A 127.0.0.2
187
188 ; -------- Testing MX records --------
189
190 mxcased MX 5 ten-99.TEST.EX.
191
192 ; Points to a host with both A and AAAA
193
194 mx46 MX 46 46.test.ex.
195
196 ; Points to two hosts with both kinds of address, equal precedence
197
198 mx4646 MX 46 46.test.ex.
199 MX 46 46b.test.ex.
200
201 ; Ditto, with a third IPv6 host
202
203 mx46466 MX 46 46.test.ex.
204 MX 46 46b.test.ex.
205 MX 46 v6.test.ex.
206
207 ; This time, change precedence
208
209 mx46466b MX 46 46.test.ex.
210 MX 47 46b.test.ex.
211 MX 48 v6.test.ex.
212
213 ; Points to a host with a working IPv4 and a non-working IPv6 record
214
215 mx46cd MX 10 46c.test.ex.
216 MX 11 46d.test.ex.
217
218 ; Two equal precedence pointing to a v4 and a v6 host
219
220 mx246 MX 10 v6.test.ex.
221 MX 10 ten-1.test.ex.
222
223 ; Lowest-numbered points to local host
224
225 mxt1 MX 5 eximtesthost.test.ex.
226
227 ; Points only to non-existent hosts
228
229 mxt2 MX 5 not-exist.test.ex.
230
231 ; Points to some non-existent hosts;
232 ; Lowest numbered existing points to local host
233
234 mxt3 MX 5 not-exist.test.ex.
235 MX 6 eximtesthost.test.ex.
236
237 ; Points to some non-existent hosts;
238 ; Lowest numbered existing points to non-local host
239
240 mxt3r MX 5 not-exist.test.ex.
241 MX 6 exim.org.
242
243 ; Points to an alias
244
245 mxt4 MX 5 alias-eximtesthost.test.ex.
246
247 ; Various combinations of precedence and local host
248
249 mxt5 MX 5 eximtesthost.test.ex.
250 MX 5 ten-1.test.ex.
251
252 mxt6 MX 5 ten-1.test.ex.
253 MX 6 eximtesthost.test.ex.
254 MX 6 ten-2.test.ex.
255
256 mxt7 MX 5 ten-2.test.ex.
257 MX 6 ten-3.test.ex.
258 MX 7 eximtesthost.test.ex.
259 MX 8 ten-1.test.ex.
260
261 mxt8 MX 5 ten-2.test.ex.
262 MX 6 ten-3.test.ex.
263 MX 7 eximtesthost.test.ex.
264 MX 7 ten-4.test.ex.
265 MX 8 ten-1.test.ex.
266
267 ; Same host appearing twice; make some variants in different orders to
268 ; simulate a real nameserver and its round robinning
269
270 mxt9 MX 5 ten-1.test.ex.
271 MX 6 ten-2.test.ex.
272 MX 7 ten-3.test.ex.
273 MX 8 ten-1.test.ex.
274
275 mxt9a MX 6 ten-2.test.ex.
276 MX 7 ten-3.test.ex.
277 MX 8 ten-1.test.ex.
278 MX 5 ten-1.test.ex.
279
280 mxt9b MX 7 ten-3.test.ex.
281 MX 8 ten-1.test.ex.
282 MX 5 ten-1.test.ex.
283 MX 6 ten-2.test.ex.
284
285 ; MX pointing to IP address
286
287 mxt10 MX 5 V4NET.0.0.1.
288
289 ; Several MXs pointing to local host
290
291 mxt11 MX 5 localhost.test.ex.
292 MX 6 localhost.test.ex.
293
294 mxt11a MX 5 localhost.test.ex.
295 MX 6 ten-1.test.ex.
296
297 mxt12 MX 5 local1.test.ex.
298 MX 6 local2.test.ex.
299
300 local1 A 127.0.0.2
301 local2 A 127.0.0.2
302
303 ; Some more
304
305 mxt13 MX 4 other1.test.ex.
306 MX 5 other2.test.ex.
307
308 ; Different hosts with same IP addresses in the list
309
310 mxt14 MX 4 ten-5-6.test.ex.
311 MX 5 ten-5.test.ex.
312 MX 6 ten-6.test.ex.
313
314 ; Non-local hosts with different precedence
315
316 mxt15 MX 10 ten-1.test.ex.
317 MX 20 ten-2.test.ex.
318
319 ; Large number of IP addresses at one MX value, and then some
320 ; at another, to check that hosts_max_try tries the MX different
321 ; values if it can.
322
323 mxt99 MX 1 ten-1.test.ex.
324 MX 1 ten-2.test.ex.
325 MX 1 ten-3.test.ex.
326 MX 1 ten-4.test.ex.
327 MX 1 ten-5.test.ex.
328 MX 1 ten-6.test.ex.
329 MX 3 black-1.test.ex.
330 MX 3 black-2.test.ex.
331
332 ; Special case test for @mx_any (to doublecheck a reported Exim 3 bug isn't
333 ; in Exim 4). The MX points to two names, each with multiple addresses. The
334 ; very last address is the local host. When Exim is testing, it will sort
335 ; these addresses into ascending order.
336
337 mxt98 MX 1 98-1.test.ex.
338 MX 2 98-2.test.ex.
339
340 98-1 A V4NET.1.2.3
341 A V4NET.4.5.6
342
343 98-2 A V4NET.7.8.9
344 A HOSTIPV4
345
346 ; IP addresses with the same MX value
347
348 mxt97 MX 1 ten-1.test.ex.
349 MX 1 ten-2.test.ex.
350 MX 1 ten-3.test.ex.
351 MX 1 ten-4.test.ex.
352
353 ; MX pointing to a single-component name that exists if qualified, but not
354 ; if not. We use the special name dontqualify to stop the fake resolver
355 ; qualifying it.
356
357 mxt1c MX 1 dontqualify.
358
359 ; MX with UTF-8 characters in its name
360
361 π MX 0 mx.π.test.ex.
362
363 ; -------- Testing SRV records --------
364
365 _smtp._tcp.srv01 SRV 0 0 25 ten-1.test.ex.
366
367 _smtp._tcp.srv02 SRV 1 3 99 ten-1.test.ex.
368 SRV 1 1 99 ten-2.test.ex.
369 SRV 3 0 66 ten-3.test.ex.
370
371 _smtp._tcp.nosmtp SRV 0 0 0 .
372
373 _smtp2._tcp.srv03 SRV 0 0 88 ten-4.test.ex.
374
375 _smtp._tcp.srv27 SRV 0 0 PORT_S localhost
376
377
378 ; -------- With some for CSA testing plus their A records -------
379
380 _client._smtp.csa1 SRV 1 2 0 csa1.test.ex.
381 _client._smtp.csa2 SRV 1 1 0 csa2.test.ex.
382
383 csa1 A V4NET.9.8.7
384 csa2 A V4NET.9.8.8
385
386 ; ------- Testing DANE ------------
387
388 ; full suite dns chain, sha512
389 DNSSEC mxdane512ee MX 1 dane512ee.
390 DNSSEC dane512ee A HOSTIPV4
391 DNSSEC _1225._tcp.dane512ee TLSA 3 1 2 3d5eb81b1dfc3f93c1fa8819e3fb3fdb41bb590441d5f3811db17772f4bc6de29bdd7c4f4b723750dda871b99379192b3f979f03db1252c4f08b03ef7176528d
392
393 ; A-only, sha256
394 DNSSEC dane256ee A HOSTIPV4
395 DNSSEC _1225._tcp.dane256ee TLSA 3 1 1 2bb55f418bb03411a5007cecbfcd3ec1c94404312c0d53a44bb2166b32654db3
396
397 ; End