Community Forums
Connect with us on LinkedIn
+ Reply to Thread
Results 1 to 5 of 5
  1. #1
    Member
    Join Date
    Oct 2005
    Posts
    34

    Default Exim, Spamassassin and X-Spam-Status Header

    Is there any way to get the 'normal' X-Spam-Status header added to emails (new SA system).?

    Cpanel does this:
    Code:
    X-Spam-Status:   	 No, score=4.6
    However, normally it also includes info on which tests gave those score points (this is from a H-Sphere server):
    Code:
    X-Spam-Status:   	 No, score=1.3 required=5.0 tests=BAYES_40,HTML_MESSAGE, URIBL_JP_SURBL autolearn=ham version=3.2.4
    How can this be enabled in cpanel?

    The Exim config includes "X-Spam-Status: Yes, score=$spam_score" and "X-Spam-Status: No, score=$spam_score", but no info on how to include the tests that accounted for the score.

    Exim & cpanel docs didn't help either.

  2. #2
    Member
    Join Date
    Jul 2005
    Posts
    15

    Default

    I haven't found a way to change X-Spam-Status, because all headers are written by exim, not spamassassin (cPanel newstyle spam system).

    But you can use X-Spam-Report to bring more information into your headers.

    1) change exim configuration (/etc/exim.conf), X-Spam-Report should be written in every, not just spam messages
    - open "WHM >> Service Configuration >> Exim Configuration Editor >> Advanced Editor"
    -> search for the following line and copy it to "condition add_header" block right below (next to X-Spam-Bar, as in the block above)

    Code:
    add_header = X-Spam-Report: $spam_report
    2) edit /etc/mail/spamassassin/local.cf with your favorite editor and add the following lines:

    Code:
    # custom X-Spam-Report header (less blah blah, more data)
    #
    report_safe 0
    clear_report_template
    report_contact spamcontact@domain.tld 
    report host: _HOSTNAME_ | contact: _CONTACTADDRESS_ | scores: _TESTSSCORES(,)_ | autolearn=_AUTOLEARN_, score=_AUTOLEARNSCORE_
    
    # Set headers which may provide inappropriate cues to the Bayesian classifier
    #
    bayes_ignore_header X-Bogosity
    bayes_ignore_header X-Spam-Flag
    bayes_ignore_header X-Spam-Status
    bayes_ignore_header X-Spam-Report
    For a list of possible values have a look at Mail::SpamAssassin::Conf - SpamAssassin configuration file >> TEMPLATE TAGS

    Cheers,
    Thomas

  3. #3
    Registered User
    Join Date
    May 2010
    Posts
    3

    Thumbs down Grrr

    I find it totally unacceptable that this isn't simply accessible within the end-user cPanel.

  4. #4
    cPanel Quality Assurance Analyst cPanelDon's Avatar
    Join Date
    Nov 2008
    Location
    Houston, Texas, U.S.A.
    Posts
    2,555
    cPanel/Enkompass Access Level

    DataCenter Provider

    Default

    Quote Originally Posted by nerrd View Post
    I find it totally unacceptable that this isn't simply accessible within the end-user cPanel.
    The end-user (web site owner) area in cPanel already includes a dedicated page to enable, disable, and setup relevant options for SpamAssassin in addition to toggling the Spam Box; this area can be accessed using cPanel via the following menu path:
    The customization being requested in the opening post of this thread is something only the server administrator may configure because of the higher level changes required, that of customizing the Exim MTA configuration. It would be an inherent security risk to grant end-users the ability to modify system-wide mail handling simply to add custom message headers; if custom message headers are desired it is the responsibility of the server administrator to implement, which they can do so using Web Host Manager (WHM) via the following menu path:

  5. #5
    Registered User
    Join Date
    May 2010
    Posts
    3

    Default Re: Exim, Spamassassin and X-Spam-Status Header

    CpanelDon, you miss the point by a mile: What is unacceptable, is that the end user can not enable the report headers. It is a failure of engineering that the end user is not able to access these options without the intervention of the administrator. It is your implementation, and not some inherent reality of software engineering, that requires that this be performed by the administrator.

Similar Threads & Tags
Similar threads

  1. spam gets through, exim.conf overrides add header poorly
    By DGermancp in forum Feature Requests for cPanel/WHM
    Replies: 1
    Last Post: 10-14-2010, 03:35 PM
  2. SpamAssassin Spam Bar Header ... Level 4 for all the accounts
    By tecnotronico in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 07-31-2007, 08:03 AM
  3. Exim.conf Spam Header Rewriter Error?
    By lkraven in forum E-mail Discussions
    Replies: 3
    Last Post: 06-29-2007, 08:49 AM
  4. Bogus X-Spam-Status header on outbound mail
    By jerrek71 in forum cPanel and WHM Discussions
    Replies: 6
    Last Post: 10-02-2006, 04:36 PM
  5. Exim Filter Doesn't Read Spam Assassin Header
    By TomA in forum cPanel and WHM Discussions
    Replies: 0
    Last Post: 11-15-2003, 09:41 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube