Prevent emails being sent as "local" or "mailnull"

GoWilkes

Well-Known Member
Sep 26, 2006
611
24
168
cPanel Access Level
Root Administrator
My server IP has recently been blacklisted on Backscatterer. Unfortunately, the new WHM system of viewing Mail Relayers doesn't work anymore*, so I'm not able to track down the exact culprit, but I see that the wide majority of my server's emails are coming from "local" or "mailnull".

I'm guessing that an account has their email set to send a bounced message, and are being bombarded with spam.

How can I prevent the server from sending these types of emails?

* From "Mail Relayers", if I choose a date from the menu and it just shows "undefined/undefined/2012". If I enter a start date like 7/1/2012 and end date 7/4/2012, I get 0 results.
 

GoWilkes

Well-Known Member
Sep 26, 2006
611
24
168
cPanel Access Level
Root Administrator
Is there a reason that I shouldn't do something like this in antivirus.exim?

Code:
if $header_from: contains "mailnull"
or $header_from: contains "local"
or $header_from: contains "postmaster"
then
  seen finish
endif
if error_message and $header_from: contains "[email protected]"
then
  finish
endif