Disable SpamAssassin By Default

akust0m

Well-Known Member
Feb 19, 2016
72
4
58
Melbourne
cPanel Access Level
Root Administrator
Hey there!

I understand that recently cPanel made an adjustment to turn on SpamAssassin by default for cPanel accounts.

How do I turn off SpamAssassin by default, but still gives users the option to enable it manually within cPanel if they wish?

Thanks!
 
Last edited:

rpvw

Well-Known Member
Jul 18, 2013
1,100
475
113
UK
cPanel Access Level
Root Administrator
v70.0.51

Home »Service Configuration »Exim Configuration Manager

Apache SpamAssassin™ Options

Apache SpamAssassin™: Forced Global ON [?]
Turn on Apache SpamAssassin™ for all accounts (i.e. with no option to disable).

Set OFF
 

akust0m

Well-Known Member
Feb 19, 2016
72
4
58
Melbourne
cPanel Access Level
Root Administrator
Thank you for your reply.

This option is already off. But a recent cPanel update (I think 68) caused SpamAssassin to be enabled by default in newly created cPanel accounts.

Setting 'Enable Apache SpamAssassin™ spam filter' to 'Off' in 'Tweak Settings' causes SpamAssassin to be unavailable for all users.

How do you override cPanel's new behavior and disable SpamAssassin by default on account creation.
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Hello @akust0m,

When creating a new account, the following option now exists under the "Settings" section as of cPanel & WHM version 70:

Enable Apache SpamAssassin™

You can uncheck this option when creating the account to disable SpamAssassin. For existing accounts, this option is changeable through WHM >> Modify an Account. This setting is also available with the following WHM API 1 functions:

WHM API 1 Functions - createacct - Developer Documentation - cPanel Documentation
WHM API 1 Functions - modifyacct - Developer Documentation - cPanel Documentation

If you don't want to manually uncheck the Enable Apache SpamAssassin™ option each time you create an account, you could setup a post account creation hook that makes use of the modifyacct WHM API 1 function. Information about hooks is available at:

Guide to Standardized Hooks - Developer Documentation - cPanel Documentation

Thank you.
 

akust0m

Well-Known Member
Feb 19, 2016
72
4
58
Melbourne
cPanel Access Level
Root Administrator
Hi @cPanelMichael

Thank you for the reply on this, I've been quite delayed on getting a reply back to you.

Are there any plans for automatic provisioning from WHMCS to disable SpamAssassin upon account activation (aside from setting up a manual hook)?

The reason I'd prefer SpamAssassin to not be activated by default is because our hosting accounts are automatically provisioned with SpamExperts as it is included for the primary domain. SpamAssassin becomes redundant and wastes extra server resources due to double scanning. Our clients only use SpamAssassin for add-on domains.

Thanks!
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,880
2,261
463
Are there any plans for automatic provisioning from WHMCS to disable SpamAssassin upon account activation (aside from setting up a manual hook)?
Hello,

I don't know of any specific plans for WHMCS to offer that functionality, but I encourage you to check with their support team to verify that information, and otherwise open a feature request via their feature request website at:

WHMCS Feature Requests

Thank you.