I have to write an application and link it to a new postfix or exim4 mail server, this application must fully read and process all incoming messages. As optional requirement it may filter some messages according to mail content. After that I need a very common mail-server.
What is the best approach for that? Is is possibile to attach an agent/filter to a MTA like postfix or exim4?
Just for clarification, this will be used for automated mail-exchange between systems and this application should read all incoming email to store some state vars in a database. However, the mail exchange will be done by standard pop3/smtp protocol, so I prefer to use a standard mailserver. I can consider both Exim or Postfix.