procmail
[Top] [All Lists]

Re: QU: Filtering by fake Domains names?

1996-03-05 17:20:39
On Tue, 05 Mar 1996 17:04:08 PST , "wolf" writes:
hello,
      I need to filter mail to the same user based on aliased domains.

name(_at_)domain1(_dot_)com    user1
name(_at_)domain2(_dot_)com    user2
name(_at_)damain3(_dot_)com    user3

Sendmail on our system does not recognize to different domains, this the
.procmailrc that i have in a dummy account of 'name'


This is my solution I just got working today.  I have what looks to be the the
same setup.  I am hoping the listmemebers will suggest improvements.

I have aliases from webmaster and info to 
name(_at_)realmachine(_dot_)domain(_dot_)com which is 
a
dummy acount with the following procmailrc. Names and domains have been changed
to protect the innocent.  I am think of writing a script to generate this file
from files with the alias format.


PATH=$HOME/bin:/usr/bin:/usr/ucb:/bin:/usr/local/bin:.
MAILDIR=$HOME
DEFAULT=$MAILDIR/
LOGFILE=$MAILDIR/from
LOCKFILE=$HOME/.lockmail

:0 
* ^TOwebmaster
{
  :0 w: $LOCKEXT
  * ^TO.*domain1\.com
  ! user1

  :0 w: $LOCKEXT
  * ^TO.*domain2\.com
  ! user2
}

:0 
* ^TOinfo
{
  :0 w: $LOCKEXT
  * ^TO.*domain1\.com
  ! user3

  :0 w: $LOCKEXT
  * ^TO.*domain2\.com
  ! user4

}

# send fallout to me
:0 w: $LOCKEXT
! rtoub(_at_)cs(_dot_)uoregon(_dot_)edu

-----------------------------------------------------------------------------
Ron Toub                                     University of Oregon 
email: rtoub(_at_)cs(_dot_)uoregon(_dot_)edu                  DES 235
WWW:  <URL:http://www.cs.uoregon.edu/~rtoub> office 346-4392 home 344-2530
finger me for PGP public key                 Mime welcome
-----------------------------------------------------------------------------