procmail
[Top] [All Lists]

Re: Filtering by list of IP

2005-12-15 02:57:00
On Wed, Dec 14, 2005 at 05:49:10PM -0800, baloo(_at_)ursine(_dot_)ca wrote:

Is there a good way to make procmail sort mail based on a list
of IPs, one on each line, in a seperate file?  I'm having some
trouble getting pointed in the right direction on this.

If by "sort" you mean deposit in various folders depending
on a found result, sure.  (I first considered that you were
asking if a mbox folder could be rearranged baased on some
criterion, and my reaction was, that's not really procmail's
fortier.)

I'm still unclear on whether you want to put the mail in
folder X if the IP appears in the file or in folder Y
if it doesn't; or if you want to sort into folders based
on the exact IP.  And are you going to look for the IP
anywhere in the header, or only in the bottom line of the
Received chain (what we might call the putative sender),
or what?  If you're talking about the handshaking that sendmail
or its equivalent sees, that wouldn't be available to
procmail (unless you had sendmail write it into a header
or something.)  Or are these IPs appearing in the mail body?
You haven't stated your premises or goals all that clearly,
I'm afraid.

Well, I'll wait for more input from you while I get more coffee,
etc. :-)

Dallman

____________________________________________________________
procmail mailing list   Procmail homepage: http://www.procmail.org/
procmail(_at_)lists(_dot_)RWTH-Aachen(_dot_)DE
http://MailMan.RWTH-Aachen.DE/mailman/listinfo/procmail

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