• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Spamassassin and Plesk 9.5.4

T

Thufir

Guest
I've been trying to write a few custom spamassassin rules, and everything went great up to the point that an email is actually scanned and marked.

I added one as a test, based on an existing email. When I run a test against the email using spamassassin -t <email file name> it shows a high score.

Content analysis details: (17.5 points, 7.0 required)

My custom rule added 20 points which is why the score of 17+. Yes I know it's high, I'm only doing this as a test. It will be set normally once I know this rule actually will work and be used.

However, when I run the same email, this time with rule checking (spamassassin --lint -D <email file name>) it shows a much lower score.

[18251] dbg: check: is spam? score=4.205 required=7

The debug information does not show that the rule matched anything at all....which makes no sense based on the other test results using -t.


This is also true when I send a new email from an outside email that should match the rule .. it shows even LOWER than the --lint results:

X-Spam-Status: No, score=2.1 required=6.0 tests=BAYES_99,HTML_IMAGE_RATIO_02, HTML_MESSAGE, HTML_TITLE_SUBJ_DIFF, MIME_HTML_ONLY, RAZOR2_CF_RANGE_51_100, RAZOR2_CF_RANGE_E8_51_100, RAZOR2_CHECK, RCVD_IN_DNSWL_HI, SPF_PASS, URIBL_RHS_DOB autolearn=no version=3.2.5

The custom rule file is in a new file in /etc/mail/spamassassin. I've also tried putting it directly into local.cf

If I purposely make a 'mistake' in the custom rules file, I do see the warning/error show using --lint. So I know the file's being loaded. It just doesn't seem to actually run the rule and have an effect.

I've tried a few varied tests using different rules and emails, and it all ends up working the same way on each try.

Would any Plesk settings affect this, or am I just missing something?

If any other information would be needed to help get this working, just let me know.

**EDIT***
For additional information, here's the versions of packages I'm using:

- Redhat Enterprise 5.7
- Spamassassin 3.2.5
 
Last edited by a moderator:
Back
Top