4-E: Greylisting

This is a very good way to lower the incoming spam.

I'll use a modified version of JMS greylisting program I got from here -> http://www.brandonturner.net/blog/2009/08/qmail-ipv6-jgreylist/

It's very simple to use and it covers all basics. If you need something more advanced, go to the site and read how the config is done.

wget http://www.bltweb.net/qmail/jgreylist-0.8-ipv6.tar.gz

tar -xzf jgreylist-0.8-ipv6.tacd



make install

nano /etc/services/qmail-smtpd/run

#add this before the "if"s part starts


# greylisting
JGREYLIST_DIR="/var/qmail/jgreylist/"; export JGREYLIST_DIR


#and then add

/var/qmail/bin/jgreylist \

#right after

exec /usr/bin/softlimit -m 256000000 \
       /usr/bin/tcpserver \
          -v -R -l "$LOCAL" -x /etc/tcp.smtp.cdb \
          -c "$MAXSMTPD" \
          -u "$QMAILDUID" -g "$NOFILESGID" 0 smtp \

#and before

/var/qmail/bin/qmail-smtpd mail.example.com \
               /home/vpopmail/bin/vchkpw /usr/bin/true 2>&1

#remember not to leave empty spaces or comments.


#restart qmail and everything should work now. if not, check the smtp logs.