SPAMCHK

1. SPAMCHK

Fabricio Benevides
fabriciomb

(usa Debian)

Enviado em 27/09/2012 - 11:09h

Bom dia tenho o seguinte script rodando com meu postfix no cloud da locaweb, mais a locaweb diz que esta passando mensagem com score maior que 5.0 como isso é possivel? Qual e a falha que eu tenho nesse script ?

Script:

# Variables
SENDMAIL="/usr/sbin/sendmail -i"
EGREP=/bin/egrep

# Number of *'s in X-Spam-level header needed to sideline message:
# (Eg. Score of 5.5 = "*****" )
SPAMLIMIT=5

# Clean up when done or when aborting.
trap "rm -f /var/mail/spamchk/out.$$" 0 1 2 3 15

# Pipe message to spamc
cat | /usr/bin/spamc -u $2 | sed 's/^\.$/../' > /var/mail/spamchk/out.$$

# Are there more than $SPAMLIMIT stars in X-Spam-Level header? :
if $EGREP -q "^X-Spam-Level: \*{$SPAMLIMIT,}" < /var/mail/spamchk/out.$$
then
# Option 1: Move high scoring messages to sideline dir so
# a human can look at them later:
mv /var/mail/spamchk/out.$$ /home/mail/spam/$2-`date +%Y-%m-%d-%R`-$$

# Option 2: Divert to an alternate e-mail address:
#$SENDMAIL xyz@xxxx.xx < /var/tempfs/out.$$

# Option 3: Delete the message
# rm -f /var/tempfs/out.$$
else
$SENDMAIL -f $1 $2 < /var/mail/spamchk/out.$$
fi

# Postfix returns the exit status of the Postfix sendmail command.
exit $?

Aguardo ajuda.


  






Patrocínio

Site hospedado pelo provedor RedeHost.
Linux banner

Destaques

Artigos

Dicas

Tópicos

Top 10 do mês

Scripts