summaryrefslogtreecommitdiff
path: root/postfix
diff options
context:
space:
mode:
authorJonas Smedegaard <dr@jones.dk>2003-07-12 13:57:59 +0000
committerJonas Smedegaard <dr@jones.dk>2003-07-12 13:57:59 +0000
commitffd88da8dc10f9c8a84880e820ac69af9e51658e (patch)
treeb4650978ba514feb18ba0665460aeffa9c55c866 /postfix
parent2fbd6450e5ef67256b93975c506815e68c4401e9 (diff)
Restructure code a bit and add some comments.
Diffstat (limited to 'postfix')
-rwxr-xr-xpostfix/postfix.sh18
1 files changed, 9 insertions, 9 deletions
diff --git a/postfix/postfix.sh b/postfix/postfix.sh
index 5381df3..a52ee9c 100755
--- a/postfix/postfix.sh
+++ b/postfix/postfix.sh
@@ -3,7 +3,7 @@
# /etc/local-COMMON/postfix/postfix.sh
# Copyright 2002-2003 Jonas Smedegaard <dr@jones.dk>
#
-# $Id: postfix.sh,v 1.19 2003-06-21 15:27:50 jonas Exp $
+# $Id: postfix.sh,v 1.20 2003-07-12 13:57:59 jonas Exp $
#
# Auto-tweak plain installed postfix Debian package
#
@@ -54,7 +54,7 @@ fi
# TLS breaks postfix if no SASL modules available (and doesn't make sense either)
# (change the test if using some other modules and avoid the plain ones)
-if [ -f /usr/lib/postfix/tlsmgr -a -f /usr/lib/sasl/libplain.so -a -f /etc/ssl/certs/postfix.pem ]; then
+if [ -f /usr/lib/postfix/tlsmgr -a -f /usr/lib/sasl2/libplain.so -a -f /etc/ssl/certs/postfix.pem ]; then
mkdir -p $confdir/sasl
echo 'pwcheck_method: pam' >$confdir/sasl/smtpd.conf
echo 'auto_transition: false' >>$confdir/sasl/smtpd.conf
@@ -108,14 +108,13 @@ else
fi
if [ -x /usr/sbin/amavisd -o -x /usr/sbin/amavisd-new ]; then
- if [ "$pf2" ]; then
- cat $confdir/master.cf | egrep -q "^smtp-amavis$sp" || \
- echo 'smtp-amavis unix - - n - 2 lmtp -o smtp_data_done_timeout=1200s -o smtp_never_send_ehlo=yes -o disable_dns_lookups=yes' >> $confdir/master.cf
- $postconf -e 'max_use = 10'
- else
- cat $confdir/master.cf | egrep -q "^smtp-amavis$sp" || \
- echo 'smtp-amavis unix - - n - 2 smtp -o smtp_data_done_timeout=1200s -o smtp_never_send_ehlo=yes -o disable_dns_lookups=yes' >> $confdir/master.cf
+ localtransport="smtp"
+ if [ "$pf2" ]; then # lmtp is slightly buggy in earlier versions
+ localtransport="lmtp" # Provides multi-session mail transaction capability and per-recipient status responses.
+ $postconf -e 'max_use = 10' # Avoid too much reuse
fi
+ cat $confdir/master.cf | egrep -q "^smtp-amavis$sp" || \
+ echo "smtp-amavis unix - - n - 2 $localtransport -o smtp_data_done_timeout=1200s -o smtp_never_send_ehlo=yes -o disable_dns_lookups=yes" >> $confdir/master.cf
cat $confdir/master.cf | egrep -q "^127.0.0.1:10025$sp" || \
echo '127.0.0.1:10025 inet n - n - - smtpd -o content_filter= -o local_recipient_maps= -o relay_recipient_maps= -o smtpd_restriction_classes= -o smtpd_helo_restrictions= -o smtpd_client_restrictions= -o smtpd_sender_restrictions= -o smtpd_recipient_restrictions=permit_mynetworks,reject -o mynetworks=127.0.0.0/8 -o strict_rfc821_envelopes=yes' >> $confdir/master.cf
$postconf -e 'content_filter = smtp-amavis:[127.0.0.1]:10024'
@@ -127,6 +126,7 @@ fi
# Support for trusted MX backup networks added
# PCRE stuff avoided, as PCRE is only optional on newest Debian packages
# RBLs replaced with those recommended by http://www.antispews.org/
+# AMaViS tweaks as documented in amavisd-new package
# Here's a convenient overview of different blackholes:
# http://rbls.org/