So... I've got a problem!
In a web hosting context, users are allowed to send mails from their websites. All mails are relayed through a unique postfix server.
I need to authenticated the senders to be able to apply quotas via cbpolicyd.
Users can use SASL to directly connect to the postfix server or they can use PHP scripts. In the last case, a header PHP-MAIL:ip-of-the-sender is added to the mail.
So I tried to make rules in header_checks but it seems that this file helps only rejecting mails not allowing.
/Authenticated sender/ OK
/./ REJECT Pas d'authentification
I know that OK just act as DUNNO so it results that REJECT applies in any case. I'm looking for a way to implement an else condition in that file...or any other ideas welcome