Hi All,
This is a common error we see when we click on the mod_security in WHM,
Error :
HTTP error 401
cgi/addon_modsec.cgi
"WHM is configured to disallow execution of unregistered applications when logged in as root or a reseller with the "all" ACL."Fix : To fix this error we need to register the Plug-in and it can be done by the following simple steps:
Check for the folder "/var/cpanel/apps" in the cPanel server, if not then create a new onemkdir /var/cpanel/apps
chmod 755 /var/cpanel/appsCreate a configuration (.conf) file for your plugin. For mod security,vi addon_modsec.conf# name
name=addon_modsec
# Service that will serve this app
service=whostmgr
# Physical path: /usr/local/cpanel/3rdparty/Foo.php
# Literal URL path: $server:$port/$cpsession/3rdparty/Foo.php
url=/cgi/addon_modsec.cgi
# System user to run process as
user=root
# Required acls
acls=any
# Display name as show in the service ui
displayname=addon_modsecThen register mod security plugin/usr/local/cpanel/bin/register_appconfig addon_modsec.confThats all, the error will disappear
In order to unregister, use this command/usr/local/cpanel/bin/unregister_appconfig addon_modsec.conf/usr/local/cpanel/bin/show_appconfig — This script displays a YAML-formatted list of applications that are registered with AppConfig and their settings.
Check the above and fix the error...
Thank you
