annotate dnsbl.conf @ 140:4028de9b46dd

cleanup smtp rate limit code
author carl
date Wed, 27 Sep 2006 08:00:13 -0700
parents f4746d8a12a3
children 31ff00ea6bfb
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
127
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
1 context main-default {
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
2 // outbound dnsbl filtering to catch our own customers that end up on the sbl
136
f4746d8a12a3 add smtp auth rate limits
carl
parents: 127
diff changeset
3 dnsbl localp partial.blackholes.five-ten-sg.com "Mail from %s rejected - local; see http://www.five-ten-sg.com/blackhole.php?%s";
127
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
4 dnsbl local blackholes.five-ten-sg.com "Mail from %s rejected - local; see http://www.five-ten-sg.com/blackhole.php?%s";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
5 dnsbl sbl sbl-xbl.spamhaus.org "Mail from %s rejected - sbl; see http://www.spamhaus.org/query/bl?ip=%s";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
6 dnsbl dul dul.dnsbl.sorbs.net "Mail from %s rejected - dul; see http://www.sorbs.net/lookup.shtml?%s";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
7 dnsbl_list local sbl dul;
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
8
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
9 // outbound content filtering to prevent our own customers from sending spam
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
10 content on {
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
11 filter sbl-xbl.spamhaus.org "Mail containing %s rejected - sbl; see http://www.spamhaus.org/query/bl?ip=%s";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
12 uribl multi.surbl.org "Mail containing %s rejected - surbl; see http://www.rulesemporium.com/cgi-bin/uribl.cgi?bl0=1&domain0=%s";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
13 #uribl black.uribl.com "Mail containing %s rejected - uribl; see http://l.uribl.com/?d=%s";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
14 ignore { include "hosts-ignore.conf"; };
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
15 tld { include "tld.conf"; };
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
16 cctld { include "cctld.conf"; };
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
17 html_tags { include "html-tags.conf"; };
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
18 html_limit on 20 "Mail containing excessive bad html tags rejected";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
19 html_limit off;
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
20 host_limit on 20 "Mail containing excessive host names rejected";
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
21 host_limit soft 20;
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
22 };
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
23
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
24 // backscatter prevention - don't send bounces for mail that we accepted but could not forward
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
25 // we only send bounces to our own customers
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
26 env_from unknown {
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
27 "<>" black;
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
28 };
136
f4746d8a12a3 add smtp auth rate limits
carl
parents: 127
diff changeset
29
140
4028de9b46dd cleanup smtp rate limit code
carl
parents: 136
diff changeset
30 // per recipient rates - only used in the default (first top level) context
4028de9b46dd cleanup smtp rate limit code
carl
parents: 136
diff changeset
31 rate_limit 30 { // default
4028de9b46dd cleanup smtp rate limit code
carl
parents: 136
diff changeset
32 fred 100; // override default limits
4028de9b46dd cleanup smtp rate limit code
carl
parents: 136
diff changeset
33 joe 10; // ""
136
f4746d8a12a3 add smtp auth rate limits
carl
parents: 127
diff changeset
34 };
127
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
35 };
2b1a4701e856 sendmail no longer guarantees <> wrapper on envelopes
carl
parents: 122
diff changeset
36
94
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
37 context main {
136
f4746d8a12a3 add smtp auth rate limits
carl
parents: 127
diff changeset
38 dnsbl localp partial.blackholes.five-ten-sg.com "Mail from %s rejected - local; see http://www.five-ten-sg.com/blackhole.php?%s";
94
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
39 dnsbl local blackholes.five-ten-sg.com "Mail from %s rejected - local; see http://www.five-ten-sg.com/blackhole.php?%s";
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
40 dnsbl sbl sbl-xbl.spamhaus.org "Mail from %s rejected - sbl; see http://www.spamhaus.org/query/bl?ip=%s";
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
41 dnsbl xbl xbl.spamhaus.org "Mail from %s rejected - xbl; see http://www.spamhaus.org/query/bl?ip=%s";
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
42 dnsbl dul dul.dnsbl.sorbs.net "Mail from %s rejected - dul; see http://www.sorbs.net/lookup.shtml?%s";
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
43 dnsbl_list local sbl dul;
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
44
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
45 content on {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
46 filter sbl-xbl.spamhaus.org "Mail containing %s rejected - sbl; see http://www.spamhaus.org/query/bl?ip=%s";
122
e8971c595845 fix typo in multi.surbl.org name
carl
parents: 119
diff changeset
47 uribl multi.surbl.org "Mail containing %s rejected - surbl; see http://www.rulesemporium.com/cgi-bin/uribl.cgi?bl0=1&domain0=%s";
119
d9d2f8699621 uribl patch from Jeff Evans <jeffe@tricab.com>
carl
parents: 117
diff changeset
48 #uribl black.uribl.com "Mail containing %s rejected - uribl; see http://l.uribl.com/?d=%s";
94
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
49 ignore { include "hosts-ignore.conf"; };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
50 tld { include "tld.conf"; };
119
d9d2f8699621 uribl patch from Jeff Evans <jeffe@tricab.com>
carl
parents: 117
diff changeset
51 cctld { include "cctld.conf"; };
d9d2f8699621 uribl patch from Jeff Evans <jeffe@tricab.com>
carl
parents: 117
diff changeset
52 html_tags { include "html-tags.conf"; };
94
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
53 html_limit off;
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
54 host_limit soft 20;
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
55 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
56
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
57 env_to {
100
63e8633abc34 allow empty env_to at global context to remove all restrictions on child contexts
carl
parents: 94
diff changeset
58 # !! replace this with your domain names
63e8633abc34 allow empty env_to at global context to remove all restrictions on child contexts
carl
parents: 94
diff changeset
59 # child contexts are not allowed to specify recipient addresses outside these domains
63e8633abc34 allow empty env_to at global context to remove all restrictions on child contexts
carl
parents: 94
diff changeset
60 # or leave this empty to allow unrestricted child contexts
63e8633abc34 allow empty env_to at global context to remove all restrictions on child contexts
carl
parents: 94
diff changeset
61 # example.com;
94
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
62 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
63
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
64 context whitelist {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
65 content off {};
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
66 env_to {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
67 # dcc_to ok { include "/var/dcc/whitecommon"; };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
68 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
69 env_from white {}; # white forces all unmatched from addresses (everyone in this case) to be whitelisted
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
70 # so all mail TO these env_to addresses is accepted
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
71 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
72
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
73 context abuse {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
74 dnsbl_list xbl;
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
75 content off {};
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
76 env_to {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
77 abuse@ # no content filtering on abuse reports
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
78 postmaster@ # ""
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
79 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
80 env_from unknown {}; # ignore all parent white/black listing
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
81 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
82
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
83 context minimal {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
84 dnsbl_list sbl dul;
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
85 content on {};
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
86 env_to {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
87 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
88 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
89
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
90 context blacklist {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
91 env_to {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
92 # dcc_to many { include "/var/dcc/whitecommon"; };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
93 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
94 env_from black {}; # black forces all unmatched from addresses (everyone in this case) to be blacklisted
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
95 # so all mail TO these env_to addresses is rejected
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
96 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
97
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
98 env_from unknown {
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
99 abuse@ abuse; # replies to abuse reports use the abuse context
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
100 # dcc_from { include "/var/dcc/whitecommon"; };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
101 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
102 };
e107ade3b1c0 fix dos line terminators
carl
parents: 92
diff changeset
103