

![]() | Start a set with this search |
![]() | Include this search in one of my sets |
![]() | Exclude this search from one of my sets |
![]() | Permalink to these results Paste this link in email or IM: |
| Atom feed for tracking future search results Paste this URL into your reader: |
3 messages in net.sourceforge.lists.courier-maildropRe: [maildropl] SpamAssassin + Qmail-...| From | Sent On | Attachments |
|---|---|---|
| Andre Fortin | Feb 5, 2004 5:41 am | |
| Ajai Khattri | Feb 5, 2004 11:17 am | |
| Andre Fortin | Feb 7, 2004 12:54 pm |

![]() | Permalink for this message Paste this link in email or IM: |
![]() | Permalink for this thread Paste this link in email or IM: |
| Atom feed for this thread Paste this URL into your reader: |
| Subject: | Re: [maildropl] SpamAssassin + Qmail-Ldap + Maildrop | Actions... |
|---|---|---|
| From: | Ajai Khattri (aj...@bway.net) | |
| Date: | Feb 5, 2004 11:17:38 am | |
| List: | net.sourceforge.lists.courier-maildrop | |
On Thu, 5 Feb 2004, Andre Fortin wrote:
I'm trying to set up a mail system, in which the MX is a 'filter', which will do virus checking and spam filtering (with SpamAssassin), and will then forward to the actual Qmail-LDAP server, which will process the mail into the correct mailbox. When a message is flagged as 'X-Spam-Status: Yes', and then forwarded to the Qmail-LDAP servers, I'd like to have Maildrop move the flagged messages to a ./Maildir/.Junk-Mail/ maildir.
Has anyone configured something like this, and would have some samples of /etc/maildroprc, /etc/maildropldap.config that they could share? I'd like to set up everything in /etc/maildroprc instead of in the users mailMessageStore dir, since there will not be many (if any) custom settings. I'm also curious if theres a way to set up the default 'deliveryProgramPath' in control files, rather than having to add the attribute for each user..
We are using SpamAssassin with qmail and maildrop successfully.
Or global mailfilter file looks like this:
SHELL="/bin/sh" import $EXT import $HOST VDIR=`pwd` USERNAME=`echo ${VDIR##*/}` USERHOST=`PWDTMP=${VDIR%/*}; echo ${PWDTMP##*/}`
`test -s "$VDIR/Maildir/maildirsize"` if ( $RETURNCODE == 1 ) { `~vpopmail/bin/vuserinfo -Q $USERNAME@$USERHOST` `/usr/sbin/chown vpopmail:vchkpw $VDIR/Maildir/maildirsize` `chmod 640 $VDIR/Maildir/maildirsize` }
if ( $SIZE < 262144 )
{
exception {
#xfilter "/usr/local/bin/spamc -d 216.220.96.26 -f -u
$EXT@$HOST"
xfilter "/usr/local/bin/spamc -f -u $USERNAME@$USERHOST"
#log "=== SPAMC called"
}
}
if (/^X-Spam-Flag: *YES/) { # try filtering it using user-defined rules #log "== SPAM YES" `test -s "$VDIR/Maildir/.mailfilter"` if ( $RETURNCODE == 0 ) { #log "= PARSING $VDIR/Maildir/.mailfilter" include $VDIR/Maildir/.mailfilter #log "== SPAM YES back from included file" } #log "== SPAM YES back from included file" # make sure .Spam folder exists `test -d ./Maildir/.Spam` if( $RETURNCODE == 1 ) { #log "= CREATING SPAMDIR" `maildirmake -f Spam ./Maildir` #log "= SUBSCRIBING SPAMDIR" `echo INBOX.Spam >> ./Maildir/courierimapsubscribed` }
# then try delivering it to a Spam folder exception { #log "= DELIVERING SPAM to $VDIR/Maildir/.Spam/" to "$VDIR/Maildir/.Spam/" } # ah well, I guess they'll just have to live with disappointment exception { #log "== SPAM YES - couldn't deliver to .Spam folder" to "$VDIR/Maildir" } } else { #log "=== SPAM NO" `test -s "$VDIR/Maildir/.mailfilter"` if ( $RETURNCODE == 0 ) { #log "= PARSING $VDIR/Maildir/.mailfilter" include $VDIR/Maildir/.mailfilter #log "== BACK FROM INCLUDE" } exception { #log "= DUMP to Maildir" to "$VDIR/Maildir" } #log "==== EXITING" to "$VDIR/Maildir" }
We call the user's .mailfilter if it exists otherwise we try to create and drop the spam into a Spam folder. We are using Courier-IMAP and vpopmail.
-- Aj. Sys. Admin / Developer







