Page 1 of 1

Exim Filters

Posted: Thu Feb 27, 2020 10:19 am
by fedekrum
Where and how can I add exim filters on vesta ?
I am trying to detect spam from my server with this tutorial but is specific for CPanel.
https://mellowhost.com/blog/how-to-trac ... -exim.html

Re: Exim Filters

Posted: Mon Mar 02, 2020 8:36 am
by plutocrat
I believe you just have to define a file for them in /etc/exim4/exim4.conf.template eg
system_filter = /etc/exim4/system_filter

Then put your commands in that file.

Also replace [email protected] for a real email address you've set up on the vestacp server to receive all the mails. As long as Spamassassin is running on your server, it should basically fulfill all the criteria.

I made my own system_filter, to re-write the Subject lines of Spam emails. It looks like this

Code: Select all

if $h_X-Spam-Status: contains "Yes"
then
    headers remove "Subject"
    headers add "Subject: $h_X-Spam-Subject"
endif