1 | #!/bin/sh |
---|
2 | |
---|
3 | export TARPITCOUNT="3" |
---|
4 | export TARPITDELAY="10" |
---|
5 | export MFDNSCHECK="" |
---|
6 | QMAILDUID=`id -u qmaild` |
---|
7 | NOFILESGID=`id -g qmaild` |
---|
8 | MAXSMTPD=`cat /opt/local/var/qmail/control/concurrencyincoming` |
---|
9 | LOCAL=`head -1 /opt/local/var/qmail/control/me` |
---|
10 | |
---|
11 | if [ -z "$QMAILDUID" -o -z "$NOFILESGID" -o -z "$MAXSMTPD" -o -z "$LOCAL" ]; then |
---|
12 | echo QMAILDUID, NOFILESGID, MAXSMTPD, or LOCAL is unset in |
---|
13 | echo /opt/local/var/qmail/supervise/qmail-smtpd/run |
---|
14 | exit 1 |
---|
15 | fi |
---|
16 | |
---|
17 | if [ ! -f /opt/local/var/qmail/control/rcpthosts ]; then |
---|
18 | echo "No /opt/local/var/qmail/control/rcpthosts" |
---|
19 | echo "Refusing to start SMTP listener because it'll create an open relay" |
---|
20 | exit 1 |
---|
21 | fi |
---|
22 | |
---|
23 | exec /opt/local/sbin/softlimit -m 30000000 \ |
---|
24 | /opt/local/bin/tcpserver -v -R -l "$LOCAL" -x /opt/local/etc/tcp.smtp.cdb -c "$MAXSMTPD" \ |
---|
25 | -u "$QMAILDUID" -g "$NOFILESGID" 0 smtp \ |
---|
26 | /opt/local/bin/rblsmtpd -t 300 \ |
---|
27 | -b -r l1.spews.dnsbl.sorbs.net \ |
---|
28 | -b -r misc.dnsbl.sorbs.net \ |
---|
29 | -b -r http.dnsbl.sorbs.net \ |
---|
30 | -b -r socks.dnsbl.sorbs.net \ |
---|
31 | -b -r smtp.dnsbl.sorbs.net \ |
---|
32 | -b -r web.dnsbl.sorbs.net \ |
---|
33 | -b -r zombie.dnsbl.sorbs.net \ |
---|
34 | -b -r dul.dnsbl.sorbs.net \ |
---|
35 | -b -r rhsbl.sorbs.net \ |
---|
36 | -b -r sbl-xbl.spamhaus.org \ |
---|
37 | /opt/local/bin/fixcrio /opt/local/var/qmail/bin/qmail-smtpd 2>&1 |
---|