Cloudron makes it easy to run web apps like WordPress, Nextcloud, GitLab on your server. Find out more or install now.


Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Bookmarks
  • Search
Skins
  • Light
  • Brite
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Brand Logo

Cloudron Forum

Apps | Demo | Docs | Install
  1. Cloudron Forum
  2. Support
  3. Is my spam filter working?

Is my spam filter working?

Scheduled Pinned Locked Moved Unsolved Support
spamemailspamassassin
4 Posts 3 Posters 71 Views 4 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • 32463 Offline
    32463 Offline
    3246
    wrote last edited by
    #1
    X-Spam-Checker-Version: SpamAssassin 4.0.0 (2022-12-13) on 65fd54c98676
    X-Spam-Status: No, score=-1.5 required=5.0 tests=RCVD_IN_MSPIKE_H4,
    	SPF_HELO_NONE autolearn=ham autolearn_force=no version=4.0.0
    

    Just got another junk mail and checked the headers... how is this able to get through?

    Why does Spamassasin think it's HAM?!

    My Mail ACL:

    af32dc754d25b4724678102fd983c597.combined.mail.abusix.zone
    zen.spamhaus.org
    bl.mailspike.net
    noptr.spamrats.com
    bl.0spam.org
    dnsbl.sorbs.net
    black.junkemailfilter.com
    all.spamrats.com
    

    My custom spamassassin rules:

    # Allow emails from mural.co and muralapp.co domains
    # Using whitelist_from_rcvd for secure validation (checks both sender and relay)
    whitelist_from_rcvd *@mural.co mural.co
    whitelist_from_rcvd *@mural.co *.mural.co
    whitelist_from_rcvd *@muralapp.co muralapp.co
    whitelist_from_rcvd *@muralapp.co *.muralapp.co
    
    # Fallback header-based rule (if relay validation fails)
    header LOCAL_ALLOW_MURAL_FROM From =~ /\@(mural|muralapp)\.co$/i
    score LOCAL_ALLOW_MURAL_FROM -5.0
    describe LOCAL_ALLOW_MURAL_FROM Email from trusted mural.co or muralapp.co domains
    
    # scoring BAYES
    score BAYES_00 -5.0
    score BAYES_05 -4.0
    score BAYES_20 1.0
    score BAYES_40 2.0
    score BAYES_50 2.5
    score BAYES_60 3.0
    score BAYES_80 3.5
    score BAYES_95 4.0
    score BAYES_99 4.5
    score BAYES_999 2.0
    
    # scoring DNSBLs & DNSWLs
    score RCVD_IN_BL_SPAMCOP_NET 2.0
    score RCVD_IN_DNSWL_BLOCKED 0
    score RCVD_IN_DNSWL_HI -6.0
    score RCVD_IN_DNSWL_LOW -2.0
    score RCVD_IN_DNSWL_MED -4.0
    score RCVD_IN_DNSWL_NONE 0.5
    score RCVD_IN_HOSTKARMA_BL 2.0
    score RCVD_IN_HOSTKARMA_BR 0.5
    score RCVD_IN_HOSTKARMA_W -5.0
    score RCVD_IN_MSPIKE_BL 0.0
    score RCVD_IN_MSPIKE_H2 -0.5
    score RCVD_IN_MSPIKE_H3 -0.5
    score RCVD_IN_MSPIKE_H4 -2.0
    score RCVD_IN_MSPIKE_H5 -3.0
    score RCVD_IN_MSPIKE_L3 0.5
    score RCVD_IN_MSPIKE_L4 2.0
    score RCVD_IN_MSPIKE_L5 3.0
    score RCVD_IN_MSPIKE_WL 0.0
    score RCVD_IN_MSPIKE_ZBI 2.0
    score RCVD_IN_PBL 3.0
    score RCVD_IN_SBL 3.0
    score RCVD_IN_SBL_CSS 3.0
    score RCVD_IN_SPAMRATS_DYNA 2.0
    score RCVD_IN_SPAMRATS_NOPTR 2.0
    score RCVD_IN_SPAMRATS_SPAM 3.0
    score RCVD_IN_XBL 3.0
    score RCVD_IN_ZEN_BLOCKED 0.0
    score RCVD_IN_ZEN_BLOCKED_OPENDNS 0.0
    
    # scoring URIBLs
    score URIBL_ABUSE_SURBL 4.5
    score URIBL_BLACK 4.5
    score URIBL_CR_SURBL 3.5
    score URIBL_CSS 2.0
    score URIBL_CSS_A 2.0
    score URIBL_DBL_ABUSE_BOTCC 3.0
    score URIBL_DBL_ABUSE_MALW 3.0
    score URIBL_DBL_ABUSE_PHISH 3.0
    score URIBL_DBL_ABUSE_REDIR 1.0
    score URIBL_DBL_ABUSE_SPAM 3.0
    score URIBL_DBL_BLOCKED 0.0
    score URIBL_DBL_BLOCKED_OPENDNS 0.0
    score URIBL_DBL_BOTNETCC 3.0
    score URIBL_DBL_ERROR 0.0
    score URIBL_DBL_MALWARE 3.0
    score URIBL_DBL_PHISH 3.0
    score URIBL_DBL_SPAM 3.0
    score URIBL_GREY 1.0
    score URIBL_MW_SURBL 3.5
    score URIBL_PH_SURBL 3.5
    score URIBL_RED 0.5
    score URIBL_RHS_DOB 2.0
    score URIBL_SBL 3.0
    score URIBL_SBL_A 3.0
    score URIBL_ZEN_BLOCKED 0.0
    score URIBL_ZEN_BLOCKED_OPENDNS 0.0
    
    # scoring DKIM & SPF
    score DKIM_INVALID 1.5
    score DKIM_SIGNED 0.0
    score DKIM_VALID 0.0
    score DKIM_VALID_AU 0.0
    score DKIM_VALID_EF 0.0
    score DKIM_VERIFIED 0.0
    score DKIMWL_BL 3.0
    score DKIMWL_WL_HIGH -3.5
    score DKIMWL_WL_MED -2.5
    score DKIMWL_WL_MEDHI -3.0
    score FORGED_SPF_HELO 3.0
    score SPF_FAIL 1.5
    score SPF_HELO_FAIL 1.5
    score SPF_HELO_NEUTRAL 1.0
    score SPF_HELO_NONE 0.5
    score SPF_HELO_PASS 0.0
    score SPF_HELO_SOFTFAIL 1.5
    score SPF_NEUTRAL 0.5
    score SPF_NONE 0.5
    score SPF_PASS 0.0
    score SPF_SOFTFAIL 1.5
    score USER_IN_DEF_DKIM_WL -5.0
    
    # scoring HTML
    score HTML_FONT_LOW_CONTRAST 0.5
    score HTML_IMAGE_ONLY_04 1.0
    score HTML_IMAGE_ONLY_08 1.0
    score HTML_IMAGE_ONLY_12 1.0
    score HTML_IMAGE_ONLY_16 1.5
    score HTML_IMAGE_ONLY_20 1.5
    score HTML_IMAGE_ONLY_24 2.0
    score HTML_IMAGE_ONLY_28 2.5
    score HTML_IMAGE_ONLY_32 3.0
    score HTML_IMAGE_RATIO_02 0.0
    score HTML_IMAGE_RATIO_04 0.0
    score HTML_IMAGE_RATIO_06 0.0
    score HTML_IMAGE_RATIO_08 0.0
    score HTML_MESSAGE 0.0
    score HTML_MIME_NO_HTML_TAG 0.5
    score HTML_SHORT_LINK_IMG_1 2.5
    score HTML_SHORT_LINK_IMG_2 1.5
    score HTML_SHORT_LINK_IMG_3 0.5
    
    # scoring HEADER & MISSING
    score HEADER_FROM_DIFFERENT_DOMAINS 0.5
    score MISSING_DATE 3.0
    score MISSING_FROM 1.5
    score MISSING_HEADERS 2.0
    score MISSING_SUBJECT 1.0
    
    # scoring FREEMAIL
    score FREEMAIL_ENVFROM_END_DIGIT 0.5
    score FREEMAIL_FORGED_REPLYTO 1.0
    score FREEMAIL_FROM 0
    score FREEMAIL_REPLY 0.5
    score FREEMAIL_REPLYTO 0.5
    score FREEMAIL_REPLYTO_END_DIGIT 0.5
    
    # additional scoring tweaks
    score HELO_DYNAMIC_SPLIT_IP 3.0
    score LOTS_OF_MONEY 0.5
    score MPART_ALT_DIFF 0.5
    score MPART_ALT_DIFF_COUNT 0.5
    score RDNS_NONE 0.5
    score T_FILL_THIS_FORM_SHORT 0.5
    score UNPARSEABLE_RELAY 0.5
    
    # add JunkEmailFilter HostKarma DNSBL & DNSWL
    header __RCVD_IN_HOSTKARMA eval:check_rbl('HOSTKARMA-lastexternal','hostkarma.junkemailfilter.com.')
    describe __RCVD_IN_HOSTKARMA Sender listed in JunkEmailFilter
    tflags __RCVD_IN_HOSTKARMA net
    header RCVD_IN_HOSTKARMA_W eval:check_rbl_sub('HOSTKARMA-lastexternal','127.0.0.1')
    describe RCVD_IN_HOSTKARMA_W Sender listed in HOSTKARMA-WHITE
    tflags RCVD_IN_HOSTKARMA_W net nice
    header RCVD_IN_HOSTKARMA_BL eval:check_rbl_sub('HOSTKARMA-lastexternal','127.0.0.2')
    describe RCVD_IN_HOSTKARMA_BL Sender listed in HOSTKARMA-BLACK
    tflags RCVD_IN_HOSTKARMA_BL net
    header RCVD_IN_HOSTKARMA_BR eval:check_rbl_sub('HOSTKARMA-lastexternal','127.0.0.4')
    describe RCVD_IN_HOSTKARMA_BR Sender listed in HOSTKARMA-BROWN
    tflags RCVD_IN_HOSTKARMA_BR net
    
    # add Spamrats DNSBL
    header __RCVD_IN_SPAMRATS eval:check_rbl('spamrats-lastexternal','all.spamrats.com.')
    describe __RCVD_IN_SPAMRATS SPAMRATS: sender is listed in SpamRats
    tflags __RCVD_IN_SPAMRATS net
    reuse __RCVD_IN_SPAMRATS
    header RCVD_IN_SPAMRATS_DYNA eval:check_rbl_sub('spamrats-lastexternal','127.0.0.36')
    describe RCVD_IN_SPAMRATS_DYNA RATS-Dyna: sent directly from dynamic IP address
    tflags RCVD_IN_SPAMRATS_DYNA net
    reuse RCVD_IN_SPAMRATS_DYNA
    header RCVD_IN_SPAMRATS_NOPTR eval:check_rbl_sub('spamrats-lastexternal','127.0.0.37')
    describe RCVD_IN_SPAMRATS_NOPTR RATS-NoPtr: sender has no reverse DNS
    tflags RCVD_IN_SPAMRATS_NOPTR net
    reuse RCVD_IN_SPAMRATS_NOPTR
    header RCVD_IN_SPAMRATS_SPAM eval:check_rbl_sub('spamrats-lastexternal','127.0.0.38')
    describe RCVD_IN_SPAMRATS_SPAM RATS-Spam: sender is a spam source
    tflags RCVD_IN_SPAMRATS_SPAM net
    reuse RCVD_IN_SPAMRATS_SPAM
    

    👉 Find our more www.bebraver.online

    1 Reply Last reply
    0
    • jamesJ james referenced this topic
    • jamesJ Offline
      jamesJ Offline
      james
      Staff
      wrote last edited by
      #2

      Hello @3246
      Also for you, in the future please try to use the template for support topics or at least give more details for your instance.
      What Cloudron version are you running?

      1 Reply Last reply
      0
      • 32463 Offline
        32463 Offline
        3246
        wrote last edited by
        #3

        Sorry James, that template is a little unwieldly for a realtively simple issuee that's not a bug or defect.

        My version is v8.3.2 (Ubuntu 24.04.3 LTS).

        👉 Find our more www.bebraver.online

        1 Reply Last reply
        2
        • jamesJ james forked this topic
        • nebulonN Offline
          nebulonN Offline
          nebulon
          Staff
          wrote last edited by
          #4

          You should see a summary in the email header just after the X-Spam-Status one, which explains how it came to this (ham) score.

          This should looks something like this, with different scores of course:

          X-Spam-Report: 
          	* -0.0 SPF_PASS SPF: sender matches SPF record
          	* -0.0 SPF_HELO_PASS SPF: HELO matches SPF record
          	* -0.1 DKIM_VALID Message has at least one valid DKIM or DK signature
          	* -0.1 DKIM_VALID_AU Message has a valid DKIM or DK signature from author's
          	*       domain
          	*  0.1 DKIM_SIGNED Message has a DKIM or DK signature, not necessarily
          	*      valid
          	* -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1%
          	*      [score: 0.0000]
          	* -0.0 RCVD_IN_DNSWL_NONE RBL: Sender listed at https://www.dnswl.org/, no
          	*      trust
          	*      [87.253.236.95 listed in list.dnswl.org]
          	*  0.0 HTML_MESSAGE BODY: HTML included in message
          
          1 Reply Last reply
          0
          Reply
          • Reply as topic
          Log in to reply
          • Oldest to Newest
          • Newest to Oldest
          • Most Votes


          • Login

          • Don't have an account? Register

          • Login or register to search.
          • First post
            Last post
          0
          • Categories
          • Recent
          • Tags
          • Popular
          • Bookmarks
          • Search