[rt-users] Solution: RT level email blocking
Steven E. Ames
sames at officescape.com
Tue Jun 20 10:34:12 EDT 2006
That's basically what I have except:
1. I don't use fetchmail
2. My procmail configuration runs everything through spamassassin:
---------------------------------------.procmailrc----------------------------------------
# eliminate duplicates (from CC, BCC, etc...)
:0 Wh: msgid.lock
| formail -D 65536 msgid.cache
# check for spam
:0fw: spamassassin.lock
| /usr/local/bin/spamc
# spam of at least 9 we don't bother with... just junk it (cron runs 'sa-learn --mbox --spam /tmp/spam')
:0:
* ^X-Spam-Level: \*\*\*\*\*\*\*\*\*
/tmp/spam
# questionable spam... check manually (<9 but higher than default threshold)
:0:
* ^X-Spam-Status: Yes
/usr/local/mailcopy/almost-certainly-spam
:0wbh
| /usr/local/rt3/bin/rt-mailgate --queue provisioning --action comment --url http://my.rt3.instance.com/
----------------------------------------------------------------------------------------------------
That's that. I occasionally go through /usr/local/mailcopy/almost-certainly-spam and save off every message in that box to either '/tmp/spam' (where it gets parsed by sa-learn later) or I bounce it to another alias that invokes rt-mailgate directly.
-Steve
-----Original Message-----
From: rt-users-bounces at lists.bestpractical.com [mailto:rt-users-bounces at lists.bestpractical.com]On Behalf Of Phil
Sent: Tuesday, June 20, 2006 10:22 AM
To: rt-users at lists.bestpractical.com
Subject: [rt-users] Solution: RT level email blocking
Thanks to all your help.
This is the solution I came up with for my fetchmail/promail/RT email blocking issue, basically I wanted th ability to block emails from certain individuals, however I did not have access to do this on the email server that handles our mail.
This is my .fetchmailrc file:
poll mail.server.ca with proto pop3 timeout 200 user 'rt' password '12345' is 'rt at localhost' here
This is my .forward file:
|/usr/bin/procmail
This is my .procmailrc file:
:0
* ^From:.*bad at user.com*
/dev/null
:0
* ^TOrt@
| /usr/local/rt3/bin/rt-mailgate --queue CustomerSupport --action correspond --url http://10.0.0.1/ <http://10.0.0.1/>
And I run the fetchmail program as follows:
fetchmail -m "/usr/bin/procmail -f %F"
So this in effect forwards all emails to the rt-mailgate script except for the email from bad at user.com
I hope this helps other people trying to get somethign like this working
Thanks again
Phil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.bestpractical.com/pipermail/rt-users/attachments/20060620/a78b94d3/attachment.htm>
More information about the rt-users
mailing list