Relying on upstream ISP spamassassin

In a default configuration, MDaemon automatically removes the existing X-Spam-Flag header on inbound mail so that pre-inserted headers don’t interfere with your local SpamAssassin configuration.

In certain cases, such as where your ISP inserts a trusted X-Spam-Flag header of their own, you may want to change this behaviour.

Changing this is pretty simple; Go to Setup –> Misc Options –> [Headers] tab, uncheck the “Strip ‘X-Spam-Flag’ option” and MDaemon will stop stripping the header.

Now, be aware you can’t use this header as input to SpamAssassin if it’s the same header that your SpamAssassin outputs, but you could use the content filter if you wanted to set this to yes if the ISP *or* local MDaemon say “Yes”

So, if you’re running a local copy of SpamAssassin too, you’ll need to make some changes.

First, edit the 10_misc.cf file and comment or change the “add_header spam Flag _YESNOCAPS_” line.

If you changed it to “add_header spam FlagX _YESNOCAPS_” then you’ll get a header called X-Spam-FlagX instead and you can use this internally.

NOTE: Normally I would not recommend editing the built-in files, normally we suggest you use local.cf or your own CF file. This is an exception as there is no way to “undo” this command, you need to remove it entirely. Also be aware that whenever you upgrade MDaemon, these changes will need to be re-done.

Once the appropriate “add_header” entry is changed, you can either use the content filter or your local SpamAssassin itself to filter on the X-Spam-Flag header.

CC BY-NC-ND 4.0 Relying on upstream ISP spamassassin by Dave Warren (everything-mdaemon.com) is licensed under a Creative Commons Attribution-NonCommercial-NoDerivatives 4.0 International License.

2 Replies to “Relying on upstream ISP spamassassin”

  1. i cant delete from the headers my IP and my ISP, what can i do to keep safe sending? i dont ant to my and isp there!

  2. mu ip is always blocklisting because of spam ,spamcorporation is saying form my IP they are getting too much spam can please tell me how can do, i am using security puls and Mdaemon10 abd avg antivirus

Leave a Reply

Your email address will not be published. Required fields are marked *

*

This site uses Akismet to reduce spam. Learn how your comment data is processed.