adding SA rule to only allow english lang mails

Questions and answers about how to do stuff
Post Reply
pfftdives
Posts: 4
Joined: 05 Jun 2019 16:12

adding SA rule to only allow english lang mails

Post by pfftdives » 26 Jul 2021 15:06

Hello,
First off- I have no need to get chinese or arabic spams and a lot come in. I did some googling and using the TextCat plugin I should be able to add:
ok_lang en
ok_locale en

and bump the UNWANTED_LANGUAGE_BODY score up to 10, and it should stop these from coming through.

I have the textcat plugin loading in init.pre, and added the rules to both local.cf and mailscanner.cf but it doesnt appear to be taking effect. I must be doing something dumb. Any suggestions?

if I check lint via the mailwatch interface or running in the cli and grep for any of these items nothing comes back. and yeah i restarted SA :) Oops. it does show the textcat plugin loading. but no ok_lang,ok_locale,UNWANTED_LANGUAGE_BODY entries. I've verified these are set in /etc/mail/spamassassin/local.cf and in /etc/MailScanner/spamassassin.cf ..

pfftdives
Posts: 4
Joined: 05 Jun 2019 16:12

Re: adding SA rule to only allow english lang mails

Post by pfftdives » 30 Jul 2021 15:23

The next day (no restarts) it started just working. YAY.

Post Reply