Maildroprc and Maildirmake
2011-09-05 09:21:40 GMT
Hello all,
I am trying to have maildrop do two things when it finds a spam message:
1) check to see if the .Spam folder exists, if it doesn’t then maildirmake it
2) deliver Spam to .Spam folder
The problem is, all mail is being sent to the .Spam folder even non-spam mail L Can anyone take a look and see what I might be doing wrong?
PS – I am just testing against the subject right now, but will later move to test against the headers. I am aware of the issues with testing the header but this is just to get started.
#
SHELL="/bin/sh"
USER="$5"
HOST="$6"
MAILHOME="/var/vmail"
DEFAULT="$MAILHOME/$HOST/$USER"
logfile "/var/vmail/maildrop.log"
if (/^Subject: ***Spam***/)
{
`test -d $MAILHOME/$HOST/$USER/.INBOX.Spam`
if( $RETURNCODE != 0)
{
`maildirmake -f INBOX.Spam $MAILHOME/$HOST/$USER`
}
exception {
to $MAILHOME/$HOST/$USER/.INBOX.Spam/
}
}
Thanks,
Matt
------------------------------------------------------------------------------ Special Offer -- Download ArcSight Logger for FREE! Finally, a world-class log management solution at an even better price-free! And you'll get a free "Love Thy Logs" t-shirt when you download Logger. Secure your free ArcSight Logger TODAY! http://p.sf.net/sfu/arcsisghtdev2dev
_______________________________________________ Courier-maildrop mailing list Courier-maildrop <at> lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/courier-maildrop
RSS Feed