El 2015-02-24 13:40, Laurent RAYSSIGUIER escribió:
Hello,

I'll need to build a mail relay which is able to count how many emails
are send by an sasl sender per month.

5000 mails per month for this one, 3000 for another one, etc…

Is there a way with postfix to do this ?

I need addon or internal functions can do this ?

Any help will be welcome.

Best regards

Laurent

You could write a basic policy service for Postfix so any outgoing e-mail (put as check_policy_service under smtpd_recipient_restrictions or smtpd_relay_restrictions if you run Postfix 2.10+) is saved in a database (MySQL, PostgreSQL, ...). This way you can make simple queries to your database backend and extract any data that you need.

More info here: http://www.postfix.org/SMTPD_POLICY_README.html

Regards.

Reply via email to