Thank you very much for your prompt help yesterday. It seems like my
maildrop is working now and tagging spam and viruses correctly. My
/etc/maildroprc has a section to pass the email through spamassassin and
clamassassin.
Now I would like to automatically remove all viruses. So should I add a
check for "X-Virus-Status: Yes" and write
to "/dev/null"
or something like that? How do I remove an email right in maildrop? I
also think I don't need to send a bounce message for the sender at all,
since it's a virus, and viruses usually automate emails from fake addresses.
The piece of /etc/maildroprc concerning antispam and antivirus is below.
Thanks.
Timothy.
#
# Scan for spam:: Spam Assassin via spamc
# Scan for virus:: ClamAV via clamassassin
#
exception {
log "$TICKS : >>> Executing spamc -u $RECIPIENT"
xfilter "$SPAMC -u $RECIPIENT"
if ( /^Content\-(?:Disposition|Transfer-Encoding|Type)\:
(?:attachment|base64|multipart)/:h )
{
log "$TICKS : >>> Executing clamassassin"
xfilter "$CLAMASSASSIN"
}
}
#
# Teach SpamAssassin
#
if ( (/^X-Spam-Flag: yes/:h) && (/^X-Spam-Level: *-----.*$:h/) )
{
cc "| $SA_LEARN --sync --spam"
}