Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
procmail recipe not working as expected
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo
View previous topic :: View next topic  
Author Message
Souperman
Guru
Guru


Joined: 14 Jul 2003
Posts: 449
Location: Cape Town, South Africa

PostPosted: Mon Dec 08, 2003 5:48 pm    Post subject: procmail recipe not working as expected Reply with quote

I have the following two recipes at the beginning of my .procmailrc:
Code:

:0
* ^X-Spam-Level: \*{10,}$
.Spam.test/

:0
* ^X-Spam-Flag: YES$
.Spam/

What I expect it to do is move any message with a SpamAssassin score >=10 to .Spam.test/ (which will ultimately be /dev/null, but I'm just testing for the moment). Other messages which are flagged as spam but with a score <10 must go to .Spam/. What's wrong with my recipe? At the moment all spam goes to .Spam/, almost like the first recipe doesn't exist. :?
_________________
moo
Back to top
View user's profile Send private message
neilhwatson
l33t
l33t


Joined: 06 Feb 2003
Posts: 719
Location: Canada

PostPosted: Mon Dec 08, 2003 7:32 pm    Post subject: Reply with quote

Could you provide an example of each of the two headers you are referencing?
_________________
The true guru is a teacher.
Neil Watson
Back to top
View user's profile Send private message
Souperman
Guru
Guru


Joined: 14 Jul 2003
Posts: 449
Location: Cape Town, South Africa

PostPosted: Tue Dec 09, 2003 6:32 am    Post subject: Reply with quote

OK, I guess you're not familiar with SpamAssassin then ... briefly then,


  • All messages which pass through SA have a "X-Spam-Level:" header which contains a string of asterisks indicating the spam score of the message, e.g. for a message which scores 3.4, "X-Spam-Level: ***"
  • When a message is deemed to be spam, SA adds a "X-Spam-Flag: YES" header


I think there's just some subtle error in my regexp for the first recipe. There are no errors in my procmail.log file.
_________________
moo
Back to top
View user's profile Send private message
neilhwatson
l33t
l33t


Joined: 06 Feb 2003
Posts: 719
Location: Canada

PostPosted: Wed Dec 10, 2003 11:16 pm    Post subject: Reply with quote

Couple of things to try.:

One, remove the $ from the end of your regex. It's not really needed.

Two, trying stating the full path to your mail folder.
_________________
The true guru is a teacher.
Neil Watson
Back to top
View user's profile Send private message
Souperman
Guru
Guru


Joined: 14 Jul 2003
Posts: 449
Location: Cape Town, South Africa

PostPosted: Tue Jan 13, 2004 10:20 am    Post subject: Reply with quote

Nope, removing the $ didn't help. The folder path isn't the problem as all my other recipes work using the relative path. It's definitely the regex. :?
_________________
moo
Back to top
View user's profile Send private message
neilhwatson
l33t
l33t


Joined: 06 Feb 2003
Posts: 719
Location: Canada

PostPosted: Tue Jan 13, 2004 2:49 pm    Post subject: Reply with quote

Try having procmail log its actions. Perhaps another rule is processing the mail prior.
_________________
The true guru is a teacher.
Neil Watson
Back to top
View user's profile Send private message
Souperman
Guru
Guru


Joined: 14 Jul 2003
Posts: 449
Location: Cape Town, South Africa

PostPosted: Tue Jan 13, 2004 5:20 pm    Post subject: Reply with quote

Nope. As per my original post, it's the very first recipe in my .procmailrc. It's simply a regex error yet I can't figure out what it should be.
_________________
moo
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Other Things Gentoo All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum