1history_redis {
2  enabled = false;
3}
4
5neural {
6  enabled = false;
7}
8
9bayes_expiry {
10  enabled = false;
11}
12
13metric_exporter {
14  enabled = false;
15}
16
17emails {
18  "whitelist" = [
19    "rspamd-test.com"
20  ]
21  rules {
22    "RSPAMD_EMAILBL_FULL" {
23        dnsbl = "test5.uribl";
24        replyto = true;
25        }
26      "RSPAMD_EMAILBL_DOMAINONLY" {
27        dnsbl = "test6.uribl";
28        domain_only = true;
29        replyto = true;
30      }
31  }
32}
33
34external_relay {
35  enabled = {= env.EXTERNAL_RELAY_ENABLED =};
36
37  rules {
38    EXTERNAL_RELAY_AUTHENTICATED {
39      strategy = "authenticated";
40      user_map = "{= env.TESTDIR =}/configs/maps/external_relay.user_map";
41    }
42    EXTERNAL_RELAY_COUNT {
43      count = 4;
44      strategy = "count";
45    }
46    EXTERNAL_RELAY_HOSTNAME_MAP {
47      hostname_map = "{= env.TESTDIR =}/configs/maps/external_relay.hostname_map";
48      strategy = "hostname_map";
49    }
50    EXTERNAL_RELAY_LOCAL {
51      strategy = "local";
52    }
53  }
54}
55
56greylist {
57  check_local = true;
58  timeout = 4;
59}
60
61logging = {
62  type = "file",
63  level = "debug"
64  filename = "{= env.TMPDIR =}/rspamd.log"
65  log_usec = true;
66}
67
68mid = {
69    source = {
70        url = [
71            "https://maps.rspamd.com/rspamd/mid.inc.zst",
72            "fallback+file://{= env.TESTDIR =}/../../../conf/mid.inc",
73            "file://{= env.TESTDIR =}/configs/maps/mid.list"
74        ];
75    }
76}
77
78mime_types {
79    file = [
80      "https://maps.rspamd.com/rspamd/mime_types.inc.zst",
81      "fallback+file://{= env.TESTDIR =}/../../../conf/mime_types.inc"
82     ];
83    extension_map {
84        html = "text/html";
85        txt [
86            "message/disposition-notification",
87            "text/plain",
88            "text/rfc822-headers",
89        ]
90        pdf [
91            "application/octet-stream",
92            "application/pdf",
93        ]
94    }
95    filename_whitelist = "{= env.TESTDIR =}/configs/maps/mime_types.wl";
96}
97
98options = {
99  pidfile = "{= env.TMPDIR =}/rspamd.pid"
100  dns {
101    nameserver = ["8.8.8.8", "8.8.4.4"];
102    retransmits = 10;
103    timeout = 2s;
104        fake_records = [{
105        # non-existent records requested by 350_surbl tests
106        name = "114.73.21.104.test4.uribl", type = "a", rcode = "norec"},
107        {name = "153.23.128.52.test4.uribl", type = "a", rcode = "norec"},
108        {name = "158.136.181.135.test4.uribl", type = "a", rcode = "norec"},
109        {name = "177.115.236.44.test4.uribl", type = "a", rcode = "norec"},
110        {name = "180.136.102.34.test4.uribl", type = "a", rcode = "norec"},
111        {name = "180.144.67.172.test4.uribl", type = "a", rcode = "norec"},
112        {name = "2.7.9.4.5.1.8.6.0.0.0.0.0.0.0.0.0.0.0.0.7.3.0.3.0.0.7.4.6.0.6.2.test4.uribl", type = "a", rcode = "norec"},
113        {name = "217.228.62.64.test4.uribl", type = "a", rcode = "norec"},
114        {name = "34.216.184.93.test4.uribl", type = "a", rcode = "norec"},
115        {name = "4.b.0.9.3.4.c.a.0.0.0.0.0.0.0.0.0.0.0.0.1.3.0.3.0.0.7.4.6.0.6.2.test4.uribl", type = "a", rcode = "norec"},
116        {name = "4eikheqjb4rb3y4oxgnfxek9wrwnyii4.test.uribl", type = "a", rcode = "norec"},
117        {name = "6.4.9.1.8.c.5.2.3.9.8.1.8.4.2.0.1.0.0.0.0.2.2.0.0.0.8.2.6.0.6.2.test4.uribl", type = "a", rcode = "norec"},
118        {name = "69so7b146n15x6qkr8rj9x8iqb7zfr1s.test.uribl", type = "a", rcode = "norec"},
119        {name = "6cqpxfrojdnzawwjmacjwtstzwehxnzb.test.uribl", type = "a", rcode = "norec"},
120        {name = "7.5.2.e.9.5.e.f.f.f.1.9.c.3.0.f.0.0.0.0.0.0.0.0.1.0.c.3.0.0.6.2.test4.uribl", type = "a", rcode = "norec"},
121        {name = "baddomain.com.test2.uribl", type = "a", rcode = "norec"},
122        {name = "baddomain.com.test3.uribl", type = "a", rcode = "norec"},
123        {name = "bbjo9td11ewijyjkq8rsn4j3kxhthz4m.test.uribl", type = "a", rcode = "norec"},
124        {name = "emailbl.com.test2.uribl", type = "a", rcode = "norec"},
125        {name = "emailbl.com.test3.uribl", type = "a", rcode = "norec"},
126        {name = "emailbl.com.test6.uribl", type = "a", rcode = "norec"},
127        {name = "example.com.test3.uribl", type = "a", rcode = "norec"},
128        {name = "example.com.test6.uribl", type = "a", rcode = "norec"},
129        {name = "example.com.test7.uribl", type = "a", rcode = "norec"},
130        {name = "example.net.test3.uribl", type = "a", rcode = "norec"},
131        {name = "example.net.test7.uribl", type = "a", rcode = "norec"},
132        {name = "example.org.test2.uribl", type = "a", rcode = "norec"},
133        {name = "example.org.test3.uribl", type = "a", rcode = "norec"},
134        {name = "example.org.test7.uribl", type = "a", rcode = "norec"},
135        {name = "example.ru.test2.uribl", type = "a", rcode = "norec"},
136        {name = "example.ru.test7.uribl", type = "a", rcode = "norec"},
137        {name = "gdhhir83i5pjk6s8i3e5afwa4md7uns7.test.uribl", type = "a", rcode = "norec"},
138        {name = "k8qo8m33z19cqejfncirs85rf4nr9h3u.test.uribl", type = "a", rcode = "norec"},
139        {name = "kr1adm7tnzuudiftdt1g4t6yg1rbt1ez.test.uribl", type = "a", rcode = "norec"},
140        {name = "rspamd.com.test2.uribl", type = "a", rcode = "norec"},
141        {name = "rspamd.com.test3.uribl", type = "a", rcode = "norec"},
142        {name = "rspamd.com.test7.uribl", type = "a", rcode = "norec"},
143        {name = "rspamd.tk.test3.uribl", type = "a", rcode = "norec"},
144        {name = "rspamd.tk.test7.uribl", type = "a", rcode = "norec"},
145        {name = "sanchez.com.test2.uribl", type = "a", rcode = "norec"},
146        {name = "sanchez.com.test3.uribl", type = "a", rcode = "norec"},
147        {name = "sanchez.com.test7.uribl", type = "a", rcode = "norec"},
148        {name = "subdomain.emailbl.com.test6.uribl", type = "a", rcode = "norec"},
149        {name = "testtest.com.test2.uribl", type = "a", rcode = "norec"},
150        {name = "testtest.com.test3.uribl", type = "a", rcode = "norec"},
151        {name = "testtest.com.test7.uribl", type = "a", rcode = "norec"},
152        {name = "user.baddomain.com.test5.uribl", type = "a", rcode = "norec"},
153        {name = "user.example.com.test5.uribl", type = "a", rcode = "norec"},
154        {name = "xn--80arbjktj.xn--p1ai.test3.uribl", type = "a", rcode = "norec"},
155        {name = "xn--80arbjktj.xn--p1ai.test7.uribl", type = "a", rcode = "norec"},
156        {name = "y84tis6xzaf41h4p5kzxiw6puixnm43k.test.uribl", type = "a", rcode = "norec"},
157        # other stuff is here too! :\
158        { # ed25519
159          name = "test._domainkey.example.com";
160          type = txt;
161          replies = ["k=ed25519; p=yi50DjK5O9pqbFpNHklsv9lqaS0ArSYu02qp1S0DW1Y="];
162        },
163        {
164          name = "brisbane._domainkey.football.example.com";
165          type = txt;
166          replies = ["v=DKIM1; k=ed25519; p=11qYAYKxCrfVS/7TyWQHOg7hcvPapiMlrwIaaPcHURo="];
167        },
168        {
169          name = "test._domainkey.football.example.com";
170          type = txt;
171          replies = ["v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDkHlOQoBTzWRiGs5V6NpP3idY6Wk08a5qhdR6wy5bdOKb2jLQiY/J16JYi0Qvx/byYzCNb3W91y3FutACDfzwQ/BC/e/8uBsCR+yz1Lxj+PL6lHvqMKrM3rG4hstT5QjvHO9PzoxZyVYLzBfO2EeC3Ip3G+2kryOTIKT+l/K4w3QIDAQAB"],
172        },
173        {
174          name = "dkim._domainkey.cacophony.za.org",
175          type = "txt";
176          replies = ["v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDXtxBE5IiNRMcq2/lc2zErfdCvDFyQNBnMjbOjBQrPST2k4fdGbtpe5Iu5uS01Met+dAEf94XL8I0hwmYw+n70PP834zfJGi2egwGqrakpaWsCDPvIJZLkxJCJKQRA/zrQ622uEXdvYixVbsEGVw7U4wAGSmT5rU2eU1y63AlOlQIDAQAB"];
177        },
178        {
179          name = "eddsa._domainkey.cacophony.za.org",
180          type = "txt";
181          replies = ["v=DKIM1; k=ed25519; p=+nU+aC33ICeS4zx8VUjFYCtxj0fRbHWQn2gP2hTkm9w="];
182        },
183        {
184          name = "dkim._domainkey.invalid.za.org",
185          type = "txt";
186          replies = ["v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDEEXmNGQq7PUrr9Mg4UakTFHgXBCy2DOztkrZm+0OrVWtiRzGluxBkbOWTBwuU3/Yw97yTphBMQxzWFN603/f/KPAQcF/Lc1l+6kmIBBxNXjjGuOK/3PYKZVntUdKmqcQBYfnHdzH2Tohbuyx1a7xqnv6VSChqQrZU4CwkeT3+eQIDAQAB"];
187        },
188        {
189          name = "eddsa._domainkey.invalid.za.org",
190          type = "txt";
191          replies = ["v=DKIM1; k=ed25519; p=Wkkrp5DJTvknDMGWYv8vm3p3sZjiQp03LZo80RregY8="];
192        },
193        {
194          name = "dkim._domainkey.rspamd.com",
195          type = "txt";
196          replies = ["v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQCd/XhZBEGGAss48lEuMmwZv9lOFf6FTllBiQ3sPhdTpDdIPaW9TInW7iYnYD/bXHeVxYAyD/sKhYk6+qGBRu10rEi+iyPvLCIED+Boq0tEQosuKuV6Fjoomb+QhZY9KdjyZTjsrFPZ+wCkUY/30uTmpX2SwSqyxxlK0pUIsRgMAQIDAQAB"];
197        },
198        {
199          name = "_dmarc.rspamd.com",
200          type = "txt";
201          rcode = 'norec';
202        },
203        {
204          name = "dkim._domainkey.highsecure.ru",
205          type = "txt";
206          replies = ["p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQDK4ZQYky30GH0Ak9OQ1fv3IdFNbpOtpa4S/PR20ZLgPXfd/FCA//ztUmu7kHlELI+/+4f8W+xX0oZlOc/cFxhopRjXZMlSsQqmWOZ40/GxWFBtcqafKu78FCqO7URqZUmMCM5Jlp4zt/yzH3dbYNG3i5PVlB5QtQnZvY+dvBL3dwIDAQAB"];
207        },
208        {
209          name = "_dmarc.cacophony.za.org",
210          type = "txt";
211          replies = ["v=DMARC1; p=none; sp=reject"];
212        },
213        {
214          name = "_dmarc.my.mom.za.org",
215          type = "txt";
216          replies = ["v=DMARC1; p=reject"];
217        },
218        {
219          name = "example.net",
220          type = "txt";
221          replies = ["v=spf1 -all"];
222        },
223        {
224          name = "fail4.org.org.za",
225          type = "txt";
226          replies = ["v=spf1 redirect=asdfsfewewrredfs"];
227        },
228        {
229          name = "_dmarc.reject.cacophony.za.org",
230          type = "txt";
231          replies = ["v=DMARC1; p=reject"];
232        },
233        {
234          name = "spf.cacophony.za.org",
235          type = "txt";
236          replies = ["v=spf1 ip4:8.8.4.4 -all"];
237        },
238        {
239          name = "fail7.org.org.za",
240          type = "a";
241          rcode = 'norec';
242        },
243        {
244          name = "fail6.org.org.za",
245          type = "txt";
246          replies = ["v=spf1 ip4:8.8.8.8 mx -all"];
247        },
248        {
249          name = "fail6.org.org.za",
250          type = "mx";
251          rcode = 'norec';
252        },
253        {
254          name = "fail7.org.org.za",
255          type = "aaaa";
256          rcode = 'norec';
257        },
258        {
259          name = "_dmarc.quarantine.cacophony.za.org",
260          type = "txt";
261          replies = ["v=DMARC1; p=quarantine"];
262        },
263        {
264          name = "_dmarc.yo.mom.za.org",
265          type = "txt";
266          replies = ["v=DMARC1; p=reject; aspf=s; adkim=s;"];
267        },
268        {
269          name = "yo.mom.za.org",
270          type = "txt";
271          replies = ["v=spf1 ip4:37.48.67.26 -all"];
272        },
273        {
274          name = "testdkim._domainkey.mom.za.org",
275          type = "txt";
276          replies = ["v=DKIM1; k=rsa; p=MIGfMA0GCSqGSIb3DQEBAQUAA4GNADCBiQKBgQC3v4VPE1QMHUzsMRbC8VzXNq82mDjiv9Gi1NB/YYC+vIYZT+sE/Uxnr0Clk8C2jgzEr3jcxgQEWZfMtEEg/EfEJvh4SrXWv9c0gw1EEfxKxX9i+r8yBQtc/EWospWVDkhF2lAvQAK1lV1ZiU7psJ6fh1CI39uZyWdAktZzWLf0zQIDAQAB"];
277        },
278        {
279          name = "_dmarc.rspamd.tk",
280          type = "txt";
281          replies = ["bio=a263adeab8acdcdb8b89e127b67d696061fdfbee"];
282        },
283        {
284          name = "fail2.org.org.za",
285          type = "txt";
286          replies = ["v=spf1 ip4:8.8.4.4 include:www.dnssec-failed.org -all"];
287        },
288        {
289          name = "fail3.org.org.za",
290          type = "txt";
291          replies = ["v=spf1 ip4:8.8.8.8 include:total.barf -all"];
292        },
293        {
294          name = "mom.za.org",
295          type = "txt";
296          replies = ["v=spf1 ip4:37.48.67.26 -all"];
297        },
298        {
299          name = "testdkim._domainkey.asdf.rspamd.tk", # testdkim._domainkey.asdf.rspamd.tk is an alias for rspamd.tk
300          type = "txt";
301          replies = ["bio=a263adeab8acdcdb8b89e127b67d696061fdfbee"];
302        },
303        {
304          name = "testdkim._domainkey.rspamd.tk", # testdkim._domainkey.rspamd.tk is an alias for rspamd.tk
305          type = "txt";
306          replies = ["bio=a263adeab8acdcdb8b89e127b67d696061fdfbee"];
307        },
308        {
309          name = "pass1.org.org.za",
310          type = "txt";
311          replies = ["v=spf1 include:pass2.org.org.za -all"];
312        },
313        {
314          name = "95.142.99.88.in-addr.arpa",
315          type = "ptr";
316          replies = ["mail.highsecure.ru"];
317        },
318        {
319          name = "mail.highsecure.ru",
320          type = "a";
321          replies = ["88.99.142.95"];
322        },
323        {
324          name = "mail.highsecure.ru",
325          type = "aaaa";
326          rcode = 'norec';
327        },
328        {
329          name = "1.0.66.128.in-addr.arpa",
330          type = "ptr";
331          rcode = 'nxdomain';
332        },
333        {
334          name = "182.216.85.209.in-addr.arpa",
335          type = "ptr";
336          replies = ["mail-qt0-f182.google.com"];
337        },
338        {
339          name = "crazyspf.cacophony.za.org",
340          type = "txt";
341          replies = ["v=spf1 ptr:cacophony.za.org ptr:rspamd.com ptr:yahoo.com ptr:yahoo.net ptr:highsecure.ru -all"];
342        },
343        {
344          name = "pass2.org.org.za",
345          type = "txt";
346          replies = ["v=spf1 ip4:8.8.8.8 -all"];
347        },
348        {
349          name = "_dmarc.yoni.za.org",
350          type = "txt";
351          replies = ["v=DMARC1; p=reject; sp=none;"];
352        },
353        {
354          name = "fail10.org.org.za",
355          type = "txt";
356          replies = ["v=spf1 redirect=fail5.org.org.za"];
357        },
358        {
359          name = "fail11.org.org.za",
360          type = "txt";
361          replies = ["v=sPF1 ip4:8.8.8.8 -all"];
362        },
363        {
364          name = "fail5.org.org.za",
365          type = "txt";
366          replies = ["v=spf1 OMGBARF"];
367        },
368        {
369          name = "fail7.org.org.za",
370          type = "txt";
371          replies = ["v=spf1 ip4:8.8.8.8 a -all"];
372        },
373        {
374          name = "trusted.com",
375          type = "txt";
376          replies = ["v=spf1 ip4:192.168.1.1"];
377        },
378        {
379          name = "external.com",
380          type = "txt";
381          replies = ["v=spf1 ip4:37.48.67.26"];
382        },
383        {
384          name = "co.za",
385          type = "txt";
386          rcode = 'norec';
387        },
388        {
389          name = "testdkim1._domainkey.yoni.za.org",
390          type = "txt";
391          replies = ["v=DKIM1; k=rsa; p=BARF"];
392        },
393        {
394          name = "_dmarc.yoni.za.net",
395          type = "txt";
396          replies = ["v=DMARC1; p=none; sp=quarantine"];
397        },
398        {
399          name = "za",
400          type = "txt";
401          replies = ["Top-level domain for South Africa"];
402        },
403        {
404          name = "_dmarc.foo.yoni.za.org",
405          type = "txt";
406          rcode = 'nxdomain';
407        },
408        {
409          name = "_dmarc.foo.cacophony.za.org",
410          type = "txt";
411          rcode = 'nxdomain';
412        },
413        {
414          name = "_dmarc.foo.yoni.za.net",
415          type = "txt";
416          rcode = 'nxdomain';
417        },
418        {
419          name = "_dmarc.dnssec-failed.org",
420          type = "txt";
421          rcode = 'timeout';
422        },
423        {
424          name = "_dmarc.example.com",
425          type = "txt";
426          rcode = 'nxdomain';
427        },
428        {
429          name = "_dmarc.zero_pct.com",
430          type = "txt";
431          replies = ["v=DMARC1; p=reject; sp=quarantine; pct=0"];
432        },
433        {
434          name = "example.com",
435          type = "txt";
436          replies = ["$Id: example.com 4415 2015-08-24 20:12:23Z davids $", "v=spf1 -all"];
437        },
438        {
439          name = "example.com",
440          type = "a";
441          replies = ["93.184.216.34"];
442        },
443        {
444          name = "testdkim1._domainkey.dnssec-failed.org",
445          type = "txt";
446          rcode = 'timeout';
447        },
448        {
449          name = "total.barf",
450          type = "txt";
451          rcode = 'nxdomain';
452        },
453        {
454          name = "_dmarc.foo.cacophony.za.org",
455          type = "txt";
456          rcode = 'nxdomain';
457        },
458        {
459          name = "zzzzaaaa",
460          type = "txt";
461          rcode = 'nxdomain';
462        },
463        {
464          name = "asdfsfewewrredfs",
465          type = "txt";
466          rcode = 'nxdomain';
467        },
468        {
469          name = "95.142.99.88.asn.rspamd.com",
470          type = "txt";
471          replies = ["24940|88.99.0.0/16|DE|ripencc|"];
472        },
473        {
474          name = "2.a.d.1.1.d.e.f.f.f.0.0.4.5.0.5.d.6.2.0.6.b.a.a.8.c.7.0.1.0.a.2.asn6.rspamd.com",
475          type = "txt";
476          replies = ["20857|2a01:7c8::/32|NL|ripencc|"];
477        },
478        {
479          name = "2.a.d.1.1.d.e.f.f.f.0.0.4.5.0.5.d.6.2.0.6.b.a.a.8.c.7.0.1.0.a.2.rspamd.com",
480          type = "txt";
481          rcode = 'nxdomain';
482        },
483        {
484          name = "2.a.d.1.1.d.e.f.f.f.0.0.4.5.0.5.d.6.2.0.6.b.a.a.8.c.7.0.1.0.a.2.rspamd.com",
485          type = "a";
486          rcode = 'nxdomain';
487        },
488        {
489          name = "rspamd.com",
490          type = "txt";
491          replies = ["v=spf1 mx -all"];
492        },
493        {
494          name = "rspamd.com",
495          type = "mx";
496          replies = ["10 mail.highsecure.ru"];
497        },
498        {
499          name = "95.142.99.88.rspamd.com",
500          type = "a";
501          rcode = 'norec';
502        },
503        {
504          name = "95.142.99.88.rspamd.com",
505          type = "aaaa";
506          rcode = 'norec';
507        },
508        {
509          name = "2.0.0.127.rspamd.com",
510          type = "a";
511          replies = ["127.0.0.1"];
512        },
513        {
514          name = "8.8.8.8.asn.rspamd.com",
515          type = "txt";
516          replies = ["15169|8.8.8.0/24|US|arin|"];
517        },
518        {
519          name = "8.8.8.8.asn.rspamd.com",
520          type = "a";
521          rcode = 'nxdomain';
522        },
523        {
524          name = "10.0.1.10.asn.rspamd.com",
525          type = "txt";
526          rcode = 'nxdomain';
527        },
528        {
529          name = "10.0.1.10.asn.rspamd.com",
530          type = "a";
531          rcode = 'nxdomain';
532        },
533        {
534          name = "10.0.1.11.asn.rspamd.com",
535          type = "txt";
536          rcode = 'nxdomain';
537        },
538        {
539          name = "10.0.1.11.asn.rspamd.com",
540          type = "a";
541          rcode = 'nxdomain';
542        },
543        {
544          name = "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.rspamd.com",
545          type = "a";
546          rcode = 'nxdomain';
547        },
548        {
549          name = "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.8.e.f.rspamd.com",
550          type = "a";
551          rcode = 'nxdomain';
552        },
553        {
554          name = "test.com",
555          type = "txt";
556          replies = [""];
557        },
558        {
559          name = "other.com",
560          type = "txt";
561          rcode = 'norec';
562        },
563        {
564          name = "bob",
565          type = "txt";
566          rcode = 'nxdomain';
567        },
568        {
569          name = "mail.highsecure.ru",
570          type = "aaaa";
571          rcode = 'norec';
572        },
573        {
574          name = "mail.highsecure.ru",
575          type = "a";
576          replies = ["88.99.142.95"];
577        },
578        {
579          name = "4.3.2.1.rspamd.com",
580          type = "a";
581          rcode = 'nxdomain';
582        },
583        {
584          name = "4.3.2.1.asn.rspamd.com",
585          type = "txt";
586          rcode = 'nxdomain';
587        },
588        {
589          name = "1.0.0.127.rspamd.com",
590          type = "a";
591          rcode = 'nxdomain';
592        },
593        {
594          name = "114.47.228.46.rspamd.com",
595          type = "a";
596          rcode = 'nxdomain';
597        },
598        {
599          name = "114.47.228.46.asn.rspamd.com",
600          type = "txt";
601          replies = ["34010|46.228.40.0/21|GB|ripencc|"];
602        },
603        {
604          name = "10.0.1.10.rspamd.com",
605          type = "a";
606          rcode = 'nxdomain';
607        },
608        {
609          name = "10.0.1.11.rspamd.com",
610          type = "a";
611          rcode = 'nxdomain';
612        },
613        {
614          name = "other.org",
615          type = "txt";
616          rcode = 'norec';
617        },
618        {
619          name = "8.8.8.8.rspamd.com",
620          type = "a";
621          rcode = 'nxdomain';
622        },
623        {
624          name = "rspamd.tk",
625          type = "txt";
626          replies = ["bio=a263adeab8acdcdb8b89e127b67d696061fdfbee"];
627        },
628        {
629          name = "fail1.org.org.za",
630          type = "txt";
631          replies = ["v=spf1 redirect=www.dnssec-failed.org"];
632        },
633        {
634          name = "www.dnssec-failed.org",
635          type = "txt";
636          rcode = 'timeout';
637        },
638        {
639          name = "www.dnssec-failed.org",
640          type = "mx";
641          rcode = 'timeout';
642        },
643        {
644          name = "www.dnssec-failed.org",
645          type = "a";
646          rcode = 'timeout';
647        },
648        {
649          name = "www.dnssec-failed.org",
650          type = "aaaa";
651          rcode = 'norec';
652        },
653        {
654          name = "cacophony.za.org",
655          type = "txt";
656          replies = ["v=spf1 redirect=asdfsfewewrredfs"];
657        },
658        {
659          name = "fail9.org.org.za",
660          type = "txt";
661          replies = ["v=spf1 ip4:8.8.8.8 mx:www.dnssec-failed.org -all"];
662        },
663        {
664          name = "fail8.org.org.za",
665          type = "txt";
666          replies = ["v=spf1 ip4:8.8.8.8 a:www.dnssec-failed.org -all"];
667        },
668        {
669          name = "1.2.3.4.fake.rbl";
670          type = "a";
671          replies = ["127.0.0.2"];
672        },
673        {
674          name = "2.2.3.4.fake.rbl";
675          type = "a";
676          replies = ["127.0.0.10"];
677        },
678        {
679          name = "3.2.3.4.fake.rbl";
680          type = "a";
681          replies = ["127.0.0.2", "127.0.0.3"];
682        },
683        {
684          name = "4.2.3.4.fake.rbl";
685          type = "a";
686          replies = ["127.0.0.2"];
687        },
688        {
689          name = "4.2.3.4.fake.wl";
690          type = "a";
691          replies = ["127.0.0.2"];
692        },
693        {
694          name = "4.3.2.1.fake.rbl";
695          type = "a";
696          rcode = 'nxdomain';
697        },
698        {
699          name = "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.8.e.f.fake.rbl";
700          type = "a";
701          replies = ["127.0.0.2"];
702        },
703        {
704          name = "131.193.18.151.fake.rbl";
705          type = "a";
706          replies = ["127.0.0.3"];
707        },
708        # SURBL tests
709        {
710          name = "rciuosbadgpq6b5wt436nhgnwzmfh9w9.test.uribl";
711          type = a;
712          replies = ["127.0.0.2"];
713        },
714        {
715          # testtest.com
716          name = "rcf1ecxtxrrpfncqzsdaiezjkf7f1rzz.test.uribl";
717          type = a;
718          replies = ["127.0.0.2"];
719        },
720        {
721          name = "jhcszdsmo3wuj5mp8t38kdisdmr3ib3q.test.uribl";
722          type = a;
723          replies = ["127.0.0.2"];
724        },
725        {
726          name = "g9ifs3q39oh5jwru94cj7ffaqd6rfyq6.test.uribl";
727          type = a;
728          replies = ["127.0.0.2"];
729        },
730        {
731          name = "xn--80arbjktj.xn--p1ai.test2.uribl";
732          type = a;
733          replies = ["127.0.1.2"];
734        },
735        {
736          name = "мойсайт.рф.test2.uribl";
737          type = a;
738          replies = ["127.0.1.2"];
739        },
740        {
741          name = "user.emailbl.com.test5.uribl";
742          type = a;
743          replies = ["127.0.0.2"];
744        },
745        {
746          name = "user.subdomain.emailbl.com.test5.uribl";
747          type = a;
748          replies = ["127.0.0.2"];
749        },
750        {
751          name = "baddomain.com.test6.uribl";
752          type = a;
753          replies = ["127.0.0.2"];
754        },
755        {
756          name = "user.subdomain.baddomain.com.test5.uribl";
757          type = a;
758          replies = ["127.0.0.2"];
759        },
760        {
761          name = "example.com.test2.uribl";
762          type = a;
763          replies = ["127.0.1.2"];
764        },
765        {
766          name = "user.example.com.test2.uribl";
767          type = a;
768          replies = ["127.0.1.5"];
769        },
770        {
771          name = "example.net.test2.uribl";
772          type = a;
773          replies = ["127.0.1.4"];
774        },
775        {
776          name = "rspamd.tk.test2.uribl";
777          type = a;
778          replies = ["127.0.1.4"];
779        },
780        {
781          name = "example.org.test3.uribl";
782          type = a;
783          replies = ["127.0.0.2"];
784        },
785        {
786          name = "example.ru.test3.uribl";
787          type = a;
788          replies = ["127.0.0.12"];
789        },
790        {
791          name = "example.ru";
792          type = a;
793          replies = ["8.8.8.8", "8.8.8.9"];
794        },
795        {
796          name = "8.8.8.8.test4.uribl";
797          type = a;
798          replies = ["127.0.0.4", "127.0.0.11"];
799        },
800        {
801          name = "uppht14nj4fsoycu3huctg9d5psx9je4.test.uribl";
802          type = a;
803          replies = ["127.0.0.2"];
804        },
805        {
806          name = "rspamd-test.com.test2.uribl";
807          type = a;
808          replies = ["127.0.1.2"];
809        },
810        {
811          name = "9.8.8.8.test4.uribl";
812          type = a;
813          replies = ["127.0.0.3"];
814        },
815        {
816          name = "4.very.dirty.sanchez.com.test7.uribl";
817          type = a;
818          replies = ["127.0.0.2"];
819        },
820        {
821          name = "clean.dirty.sanchez.com.test7.uribl";
822          type = a;
823          replies = ["127.0.0.2"];
824        },
825        {
826          name = "not.dirty.sanchez.com.test7.uribl";
827          type = a;
828          replies = ["127.0.0.2"];
829        },
830        {
831          name = "41.black.sanchez.com.test7.uribl";
832          type = a;
833          replies = ["127.0.0.2"];
834        },
835        {
836          name = "black.sanchez.com.test7.uribl";
837          type = a;
838          replies = ["127.0.0.2"];
839        },
840        {
841          name = "dirty.sanchez.com.test8.uribl";
842          type = a;
843          replies = ["127.0.0.2"];
844        },
845        {
846          name = "very.dirty.sanchez.com.test8.uribl";
847          type = a;
848          replies = ["127.0.0.2"];
849        },
850        {
851          name = "41.black.sanchez.com.test8.uribl";
852          type = a;
853          replies = ["127.0.0.2"];
854        },
855        {
856          name = "black.sanchez.com.test8.uribl";
857          type = a;
858          replies = ["127.0.0.2"];
859        },
860        {
861          name = "example.com.test9.uribl";
862          type = a;
863          replies = ["127.0.0.2"];
864        },
865        {
866          name = "example.org.test9.uribl";
867          type = a;
868          replies = ["127.0.0.2"];
869        },
870        {
871          name = "8.8.8.8.test9.uribl";
872          type = a;
873          replies = ["127.0.0.2"];
874        },
875        {
876          name = "site.resolveme",
877          type = "a";
878          replies = ["127.0.0.1"];
879        },
880        {
881          name = "not-resolvable.com",
882          type = "a";
883          rcode = 'norec';
884        },
885        # TODO: add IPv6 tests
886        ];
887  }
888}
889
890phishing {
891  symbol = "PHISHING";
892  strict_domains = {
893    STRICT_PHISHING = [
894      "{= env.TESTDIR =}/configs/maps/strict.phishing",
895    ];
896    STRICTER_PHISHING = [
897      "{= env.TESTDIR =}/configs/maps/stricter.phishing"
898    ]
899  }
900}
901
902redis {
903  servers = "{= env.REDIS_ADDR =}:{= env.REDIS_PORT =}";
904  expand_keys = true;
905}
906
907regexp {
908  CONFIG_SELECTOR_RE_RCPT_SUBJECT {
909    re =  'test=/test@user.com some subject/$',
910    score = 100500,
911  }
912}
913
914spf {
915  external_relay = [
916        "{= env.TESTDIR =}/configs/maps/external_relay_ip.list",
917  ];
918}
919
920symbols {
921  FOUR_POINTS = {
922    score = 4.0,
923  }
924  SYM1 = {
925    score = 1.0,
926  }
927}
928
929worker "controller" {
930    bind_socket = "{= env.LOCAL_ADDR =}:{= env.PORT_CONTROLLER =}";
931    keypair {
932        pubkey = "{= env.KEY_PUB1 =}";
933        privkey = "{= env.KEY_PVT1 =}";
934    }
935}
936
937worker "normal" {
938    count = 1;
939    bind_socket = "{= env.LOCAL_ADDR =}:{= env.PORT_NORMAL =}";
940    keypair {
941        pubkey = "{= env.KEY_PUB1 =}";
942        privkey = "{= env.KEY_PVT1 =}";
943    }
944}
945