procmail
[Top] [All Lists]

Re: Limiting To: and Apparently To: Fields

1997-01-23 01:07:28
On Wed, 22 Jan 1997 12:37:18 -0200 (EDT),
Isamar Villas Boas Perrelli Maia <isamar(_at_)magiclink(_dot_)com(_dot_)br> 
wrote:
On Wed, 22 Jan 1997, era eriksson wrote:
On Wed, 22 Jan 1997 02:50:45 -0500,
Scott Anguish <sanguish(_at_)digifix(_dot_)com> wrote:
For example if the From (or ^TO) has a dozen users (or say 20 or
whatever) I want to treat it as spam...
Count the number of commas. 
<...>
(.+,)(.+,)(.+,)(.+,)(.+,)(.+,)
Can Procmail limit To: and Apparently To: Fields on the mail?

Take a look at the scoring mechanism. 

:0
* -2^0
* 1^1 ^(Apparently-)?To:
/dev/null

This will give each message a default score of minus two, then add one
for each occurrence of a [header] line that matches the given regexp.
In the end, the action will be taken if the score is positive. (Note
that this doesn't count commas -- a To: line will only get a score of
1 regardless of how many recipients it contains. I believe this can be
taken care of somehow, too ...)

(This was gleaned more or less directly from the first example in the
procmailsc(5) man page. I hope I got it right.)

/* era */

-- 
See <http://www.ling.helsinki.fi/~reriksso/> for mantra, disclaimer, etc.
* If you enjoy getting spam, I'd appreciate it if you'd register yourself
  at the following URL:  <http://www.ling.helsinki.fi/~reriksso/spam.html>

<Prev in Thread] Current Thread [Next in Thread>