Linux/Mailserver/Fail2ban

From Wiki
< Linux‎ | Mailserver
Revision as of 22:06, 31 August 2016 by Marcluer (talk | contribs) (→‎/etc/fail2ban/filter.d/postfix.local)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)

/etc/fail2ban/jail.local

[postfix]
enabled  = true
maxretry = 3
bantime  = 21600
findtime = 3600
port     = smtp,465,submission
logpath  = /var/log/mail/mail.log
           /var/log/mail/mail.err



/etc/fail2ban/filter.d/postfix.local

  • add:
 ^%(__prefix_line)slost connection after (?:AUTH|UNKNOWN) from \S+\[<HOST>\]$