Php – Filter email in POSTFIX with PHP

email-serverPHPpostfix

I want to create mail server using postfix and i want to create simple scrip using php to filter incoming email. so the diagram is like this :
incoming email–>postfix–>php filter–>postfix–>destination address.
The questions are:
1. How to set up postfix so it will send incoming email to my php script?
2. How to configure php to send back incoming email to postfix after filtering?
Mail server is build in ubuntu 11.04.

Thank you

Best Answer

http://www.postfix.org/MILTER_README.html
There is a PHP milter SAPI. (I know nothing about it.)

Related Topic