• Plesk Uservoice will be deprecated by October. Moving forward, all product feature requests and improvement suggestions will be managed through our new platform Plesk Productboard.
    To continue sharing your ideas and feedback, please visit features.plesk.com

Resolved How to reduce Spam forwarding with fail2ban

TorbHo

Regular Pleskian
Most spam on our servers is blocked by different spamassasin and combined fail2ban rules, but this time the Spam was forwarded to external mail-addresses, because our clients love to use their private mail-addresses and have set a forwarding-rule.

How can we use fail2ban to block Servers sending spam?

My idea: for example when 50 Mails in about 1 hour have been marked by spamassasin as spam, this ip is blocked by fail2ban.
How could the regex for this filter-rule look like?
 
Spamassassin uses a number of rules to decide if an email is blocked and creates a score of each email. This is normally included in the header of each email, so you can see which rules have trigged.

If you can build a cron or so what counts the number of mails to specific-addresses and check how many have the score xy, you could block them with fail2ban.

Just an idea.
 
Back
Top