You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spamassassin.apache.org by Apache Wiki <wi...@apache.org> on 2008/04/16 17:25:51 UTC
[Spamassassin Wiki] Update of "IntegratedSpamdInPostfix" by JamieMcCarthy
Dear Wiki user,
You have subscribed to a wiki page or wiki category on "Spamassassin Wiki" for change notification.
The following page has been changed by JamieMcCarthy:
http://wiki.apache.org/spamassassin/IntegratedSpamdInPostfix
The comment on the change is:
My bash's test recommends = over ==, and its trap demands TERM over SIGTERM
------------------------------------------------------------------------------
smtp inet n - n - - smtpd -o content_filter=spamassassin
...
}}}
- ## you can change the maxproc to 400 if you have a strong server (dual xeon 2.8 nd above) and the preformance will be much better.
+ ## you can change the maxproc to 400 if you have a strong server (dual xeon 2.8 nd above) and the performance will be much better.
Then, go to the end of the file, and add this:
{{{
# ==========================================================================
@@ -91, +91 @@
fi
# Clean up when done or when aborting.
- trap "rm -f $OUTPUT" EXIT SIGTERM
+ trap "rm -f $OUTPUT" EXIT TERM
$SPAMASSASSIN -x > $OUTPUT
return="$?"
- if [ "$return" == 1 ]; then
+ if [ "$return" = 1 ]; then
echo "Message content rejected"
exit $EX_UNAVAILABLE
elif [ "$return" != 0 ]; then
/usr/bin/logger -s -p mail.warning -t filter \
- "Temporary SpamAssassin failure (spamc return $return)"
+ "Temporary SpamAssassin failure (spamc returned $return)"
exit $EX_TEMPFAIL
fi
@@ -165, +165 @@
fi
# Clean up when done or when aborting.
- trap "rm -f $OUTPUT" EXIT SIGTERM
+ trap "rm -f $OUTPUT" EXIT TERM
$SPAMASSASSIN -x -E -u $USER > $OUTPUT
return="$?"
- if [ "$return" == 1 ]; then
+ if [ "$return" = 1 ]; then
$NEW_COMMAND < $OUTPUT
exit $?
elif [ "$return" != 0 ]; then
- /usr/bin/logger -s -p mail.warning -t filter "Temporary SpamAssassin failure (spamc return $return)"
+ /usr/bin/logger -s -p mail.warning -t filter "Temporary SpamAssassin failure (spamc returned $return)"
exit $EX_TEMPFAIL
fi
@@ -181, +181 @@
exit $?
}}}
- This causes incoming smtp mail to be checked for spam. If the mail's spam score exceeds the threshold (set in local.cf, or in ~/.spamassassin/user_prefs) then it is redirected to the spamvac account. Otherwise it is passed on to the intended recipient. Bounces no longer occur except on a true error condition.
+ This causes incoming smtp mail to be checked for spam. If the mail's spam score exceeds the threshold (set in local.cf, or in ~/.spamassassin/user_prefs) then `spamc -E` returns 1 and the mail is redirected to the spamvac account. Otherwise it is passed on to the intended recipient. Bounces no longer occur except on a true error condition.