Help creating exim service filter

Operating System & Version
CentOS 7.9
cPanel & WHM Version
Apr 12, 2018
cPanel Access Level
Root Administrator
I am looking to create a filter on exim so that if the username sending equals [email protected] and the email contains an attachment, then send, but if it doesn’t, don’t send it.

One of our customers has an NVR that sends email alerts when it detects motion. The problem is it sends 3 emails - one saying alert opened, one with the alert and a picture, and one saying alert closed.

We got one of our IPs blacklisted by google because they had company over and it sent 30 emails instead of 10 in one hour. It will always send using the same email to a specific recipient so if sender equals X and receiver equals Y, I need to filter it so that if there’s no attachment (the image), just discard the email.

How can this be done? I found this page from docs but I don’t know the syntax to use:

Thanks :)
Last edited by a moderator:


Jurassic Moderator
Staff member
Oct 19, 2014
cPanel Access Level
Root Administrator
Hey there! This definitely falls under the "anything is doable" type of request, but you'll have to dig into the Exim filter documentation to come up with a custom solution as I don't have anything ready-made that would handle this type of work. If you do find something, please share!