LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices

Reply
 
LinkBack Search this Thread
Old 05-06-2004, 10:45 AM   #1
Liberator
LQ Newbie
 
Registered: May 2004
Posts: 3

Rep: Reputation: 0
Procmail and spamassassin question


I'm trying to set up a rule in procmail that will show the spam score in the body of the email. I'm not sure if it's possible, but it would be a great help if it worked.

I'm using fetchmail to download the emails from several accounts. Procmail then sorts the emails according to some rules. One of those rules i want be that if the email is to my "spam account", i want spamassassin to check it and write the "X-Spam-Status" line in the body of the email, so it will be easier for me to adjust spamassassin scores.

Can this be done? Any help is appreciated.

Thanx in advance.

Regards,
Liberator
 
Old 05-06-2004, 12:23 PM   #2
mako747
Member
 
Registered: Mar 2004
Location: Canada
Distribution: Slackware
Posts: 92

Rep: Reputation: 15
Forgive me if I get this wrong.

I currently use procmail to pipe our mail through spamassassin.

It writes the score to the subject line and also to the headers of the message.

Is this what you are trying to do?
 
Old 05-06-2004, 02:46 PM   #3
Liberator
LQ Newbie
 
Registered: May 2004
Posts: 3

Original Poster
Rep: Reputation: 0
Almost...

Although i want that line to be the first line in the body of the email, putting it in the subject will work as well. And of course i want it to be in the headers too.

How do u do that?
 
Old 05-06-2004, 02:56 PM   #4
mako747
Member
 
Registered: Mar 2004
Location: Canada
Distribution: Slackware
Posts: 92

Rep: Reputation: 15
In my procmailrc file I have the following line after it passes through some other stuff...

:0fw
* < 256000
| spamc

That pipes it through spamassassin
Then I have the following lines in my spamassassin/local.cf file...


# How many hits before a message is considered spam.
required_hits 5.0

# Whether to change the subject of suspected spam
rewrite_subject 1

# Text to prepend to subject if rewrite_subject is used
subject_tag *****SPAM***** SCORE _HITS_

# Encapsulate spam in an attachment
report_safe 2

# Use terse version of the spam report
use_terse_report 1
 
Old 05-06-2004, 03:47 PM   #5
Liberator
LQ Newbie
 
Registered: May 2004
Posts: 3

Original Poster
Rep: Reputation: 0
Ok... I thought i had to do it in the procmailrc. But instead it looks like i should have read more about spamassassin... he he.

Thanxs. I'll give it a try later.
 
Old 08-13-2004, 03:24 PM   #6
jymbo
Member
 
Registered: Jan 2003
Posts: 217

Rep: Reputation: 30
Rather, I find that this portion works for me in /etc/mail/spamassassin/local.cf:

Quote:
# How many hits before a message is considered spam.
required_hits 5.0

# Whether to change the subject of suspected spam
rewrite_subject 1

# Text to prepend to subject if rewrite_subject is used
subject_tag *****SPAM***** SCORE _HITS_

# Encapsulate spam in an attachment
report_safe 2

# Use terse version of the spam report
use_terse_report 1
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Spamassassin and procmail zamri Linux - Networking 2 07-16-2005 06:40 AM
fetchmail procmail spamassassin VincentB Linux - Software 4 08-24-2004 01:35 PM
spamassassin w/ procmail vs. spamassassin w/sendmail bleunuit Linux - Networking 1 08-01-2004 07:12 AM
Problems with Procmail + Spamassassin timread Linux - Software 2 01-15-2004 09:11 AM
Procmail not working with sendmail/spamassassin xichimos Linux - Networking 0 09-14-2003 01:01 PM


All times are GMT -5. The time now is 02:47 PM.

Main Menu
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration