Greylisting must be disabled on the domain you are sending to for this test to work.
To test the Spamassassin Milter, it is necessary to send a Gtube test spam email using the command below (Replacing emailonserver@example.com with a real email account on the server).
If the Anti-spam is working correctly you will see it listed in the maillog and in Warden log under Warden
-> Logs
-> Spam Log
. While testing, note that Gtube test email gives +1000 scores to spam.
So, even if a mailbox is in the whitelist, mail still be detected as spam because whitelisted email gets -100 scores.
echo "XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X" | mail -S smtp=localhost -r sender@example.com -s "Spam test example" emailonserver@example.com
apt-get install s-nail
echo "XJS*C4JDBQADN1.NSBN3*2IDNEN*GTUBE-STANDARD-ANTI-UBE-TEST-EMAIL*C.34X" | s-nail -S smtp=localhost -r sender@example.com -s "Spam test example" emailonserver@example.com
// restart spamd
systemctl restart spamassassin.service
// restart spamass-milter
systemctl restart spamass-milter.service
// restart spamd
/etc/init.d/spamassassin restart
// restart spamass-milter
/etc/init.d/spamass-milter restart
// restart spamd
/etc/init.d/spamassassin restart
// restart spamass-milter
/etc/init.d/spamass-milter restart
spamassassin -D < /usr/share/doc/spamassassin-<version number>/sample-spam.txt
spamassassin -D < /usr/share/doc/spamassassin/examples/sample-spam.txt
spamassassin -t -D razor2 < /usr/share/doc/spamassassin-<version number>/sample-spam.txt
spamassassin -t -D razor2 < /usr/share/doc/spamassassin/examples/sample-spam.txt
spamassassin -D --lint 2>&1 | grep -i failed