[Esd-l] postfix gateway

Benoit des Ligneris benoit.des.ligneris at physique.usherb.ca
Thu Oct 25 08:17:01 PDT 2001


Hello,

Well, postfix is acting as a gateway now but only the local mail is filtered
via the mailbox_command delivery parameter.

mailbox_command = /usr/bin/procmail -Y -a $DOMAIN /etc/procmailrc

Now, I find some interesting hint on how to filter all the mails going thru
postfix via the content_filter parameter:

In main.cf :
content_filter = vscan:
vscan_destination_recipient_limit = 100
vscan_destination_concurrency_limit = 5

And the definition of the filter vscan in master.cf :
vscan   unix    -       n       n       -       5       pipe user=virusck
    argv=/usr/bin/procmail -m /etc/procmailrc ${sender} ${recipient}
localhost:2525 inet n  -       n       -       -       smtpd
     -o content_filter=

So what it does is :
1) All mail coming thru is analysed by the mail sanitizer
2) Once it is scanned (modified or not !) it has to be delivered to
   localhost at port (for instance) 2525 where a postfix instance is listening
3) All mail coming in localhost:2525 is delivered WITHOUT filtering
	(content_filter is empty for this "host")

However (too easy isn't it ?)

I can't find a way to tell procmail in general and the anomaly email sanitizer
to redirect the mail to localhost:2525 AFTER the processing.

Can anybody see a [simple and computive unintensive] way to do it directly in
procmail ?

By calling another program ?

When the solution will be operational, I will make a web page describing all the
procedure.

Thank you by advance for any hint on how to achieve that.

Best regards,

Ben
-- 
 L'homme vraiment vertueux n'a pas conscience de sa vertu.
 L'homme de pihtre vertu pense sans cesse ` elle, et, en
 consiquence, il n'a pas de viritable vertu.
 La vrai vertu est spontanie et ne se pritend pas vertueuse.
                                Lao-Tseu

Benoit des Ligneris 
ICQ : 12052994
http://www.physique.usherb.ca/~bligneri/ 
Tel. Travail : (819) 821-8000 3072 ou 3018 
fax.         : (819) 821-8046
Key Fingerprint : 3A58 11D1 686A B4D4 5220  BB34 7D98 BF45 B57B 85B8
 11:06am  up 13 days, 21:55,  5 users,  load average: 0.07, 0.02, 0.00



More information about the esd-l mailing list