M
M
m5xim2019-08-05 12:39:45
postfix
m5xim, 2019-08-05 12:39:45

How to make friends between postfix and fail2ban?

The server is on ubuntu, sending emails via postfix (+opendkim) is configured.
Fail2ban was sending emails incorrectly by ignoring sendername & sender parameters in jail.local
Solution
fail2ban sends mail using mta sendmail|mail of choice, default being sendmail.
Therefore, you need to install the mailutils package (for the mail command to become available), specify the mta=mail parameter in jail.local and make sure that the mail (dkim+dmark+spf) is configured for FQDN (full quality domain name), as fail2ban will send as [email protected] The sendername & sender options only work for sendmail.

Answer the question

In order to leave comments, you need to log in

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question