procmail
[Top] [All Lists]

Re: This has got to be a FAQ pretty soon...

1997-12-09 00:55:47
On Tue, 09 Dec 1997 00:30:12 -0600, seebs(_at_)plethora(_dot_)net (Peter 
Seebach)
wrote:
Can anyone suggest a good way to spell "From and To are the same, and
don't look local"?

How's this:

    :0
    * ! ^From:[^(_at_)]+$
    * ! ^From:(_dot_)*(_at_)plethora\(_dot_)net\>
    * ! ^FROM_DAEMON
    *   ^To: \/.*
    * $ ^From: $\MATCH
    { ... deal with it ... }

I also check for To: equal to Reply-To: (change ^From to
^(From|Reply-To)). Checking that it's not ^FROM_DAEMON should exclude
well-behaved mailing lists as well as various bounces and
informational messages.

Also, let's say I want to bounce everything as user unknown, but I don't
want to get returned bounces when the from address was illegitimate.  Is
there an obvious way to do this?  The naive "just bounce as user unknown"
gets bounces to postmaster on our attempts to bounce spam...

Would adding a Precedence: junk header to your bounce message fix that?

/* era */

-- 
 Paparazzi of the Net: No matter what you do to protect your privacy,
  they'll hunt you down and spam you. <http://www.iki.fi/~era/spam/>