[SOLVED] RSPAMD whitelisted domains and senders getting marked a spam

Discussion in 'General' started by Curtis Maurand, Jan 6, 2025.

  1. Hello,
    I have a 3.2.11p1 version running on Devuan Daedalus (Debian Bookworm without systemd). It is mostly working just fine apart from rspamd. I have been reading lots of posts on this subject, but haven't found a solution that works.

    I have whitelisted several domains and senders in the gui. I have tried emptying the users folder and resyncing mail services as one post suggested. I have also tried adding a multimap as another post has suggested. I'm the best guinea pig for experiments since I'm on several mailing lists. But more and more, my junk folder is filled with legitimate mail marked as spam. I have been dutifully using the learn page to get these messages learned as ham, but it seems not to have any effect. I've added complete emails and domains to be whitelisted, yet the mails still get marked as spam. More and more it seems that I should look at my Junk folder before I look at my inbox.

    The configuraton looks ok and I do not use the configuraton tab in the rspamd gui. I just use it for classifying messages and checking status/throughput.

    Is there anything that I should look at? What do you need to see?
     
  2. Taleman

    Taleman Well-Known Member HowtoForge Supporter

    How have you done the whitelisting? There is more than one way to do it.
     
    ahrasis likes this.
  3. Hello,

    Most of the whitelisting has been done in the ispconfig GUI. Most of them are set with a priority of 8. The entries are making their way into
    Code:
     /etc/rspamd/local.d/users
    Then I added
    Code:
    /etc/rspamd/local.d/multimap.conf
    Code:
    WHITELIST_SENDER_DOMAIN {
          type = "from";
          filter = "email:domain";
          map = "/${LOCAL_CONFDIR}/local.d/whitelist.sender.domain.map";
          action = "accept";
     }
    
    and then
    Code:
     "/etc/rspamd/local.d/whitelist.sender.domain.map"
    has a list of domains to accept one per line.

    Thanks,
    Curtis
     
    Last edited: Jan 8, 2025
  4. Ham learning is being done through the rspamd gui and doesn't seem to be having any effect. If anything, the problem is getting worse. To be sure I only classified around 300 messages. I keep classifying messages from the same source over and over and yet they continue to get marked as spam.
     
  5. pyte

    pyte Well-Known Member HowtoForge Supporter

    After adding the multimap rule did you restart rspamd?
    Are there any errors when running `rspamadm configtest`?

    When writing rules like this that has a accept/reject decision it would be wise to enable `prefilter = true;` as you don't want to check any rules before/after.
     
  6. I didn't run the configtest, but I just did and it came up ok. I did restart rspamd. No whitelisting is being respected and I'll need to figure that out, but I've since changed the report ham score in statistics_group.conf to -8 and things are much better. I'm now getting 34% rewrite subject where I was getting something like 52% rewrite subject. I've run the ham classify up to 352. There wasn't enough ham classifies. So I can probably say this is solved.

    I'd love to find out where the general scores are mapped so that I could change some of the scores. I had to do that with spamassassin in the past.

    Thank you all for your help.
    --Curtis
     

Share This Page