Hello,
I encounter a new problem since one month.
Bellow all details about my config server:
- OS: CentOS Linux release 7.3.1611 (Core) x64 (fresh install)
Webmin-1.831-1 or older version.
Comodo WAF 2.20.1
Current rules version 1.111 (Latest version)
CWAF plugin version 2.20.1 (Latest version)
Webmin is installed at the end of server configuration.
There is no problem for compiling and configuring the DA.
Comodo interface run perfectly on Directadmin.
Everything work normaly.
At the end, I install webmin-1.831-1 (by yum install or RPM installation).
The webmin installation works fine and centos do not prompt any error.
But after I opened the menu “Comodo WAF 2.20.1” on my directadmin panel, and I have this error:
/ Bin / sh: /usr/local/cwaf/scripts/cwaf-wrapper.pl: Permission denied
Web Application Firewall | Free ModSecurity Rules from Comodo
MainConfigurationSecurity EngineUserdataFeedbackCatalogProtection Wizard
Current rules version 1.111 (Connection error: /usr/local/cwaf/scripts/cwaf-wrapper.pl) Restore rules
CWAF plugin version 2.20.1 (Latest version)
And Comodo WAF interface does not work.
Modsecurity is working but in directadmin the interface show some errors.
I think there is a conflict betwen Comod and Webmin. (maybe the last version of comodo or last version of webmin)
However I set nothing inside webmin.
Can you check this problem and help me to solved this conflict.
I think this conflict appeared since the last version of Comodo.
We see this conflict with Centos 6.8 in x64 with the same configuration in DA with older webmin version.
But the comod waf version is update.
In advance thank you for your help 
Hello.
We have never used/tested our plugin with several WHMS on the same server.
DirectAdmin and WebMin are independent software and our plugin is usually built in one of them in installation.
Please, check permissions on /usr/local/cwaf/scripts
Hello,
I have check the permissions for the folder and sub-folder : /usr/local/cwaf/scripts before and after installed webmin.
The permissions and owner are exactly the same.
What happening during the webmin installation ?
Because the webmin installation make one or many change on files (permissions or owner) and deny or block access to read / write or execute on file(s).
What about the cwaf configuration change since the last months ?
I want to resolv this problem, but I don’t know what can I start my analyse for debuging.
In advance thank you for your help.
Could you show us permissions on /usr/local/cwaf/scripts ?
Yes with pleasure,
[root@vps local]# ls -thal
total 92K
drwxr-xr-x 10 cwaf_plugin cwaf_plugin 4.0K Feb 9 18:01 cwaf
drwxr-xr-x. 2 root root 4.0K Feb 9 17:59 etc
drwxr-xr-x. 2 root root 4.0K Feb 9 17:53 bin
drwxr-xr-x. 12 root root 4.0K Feb 9 17:53 include
drwxr-xr-x. 8 root root 4.0K Feb 9 17:53 lib
drwxr-xr-x. 23 root root 4.0K Feb 9 17:53 .
lrwxrwxrwx 1 root root 22 Feb 9 17:53 awstats → /usr/local/awstats-7.6
drwxr-xr-x 10 root root 4.0K Feb 9 17:53 php56
drwxr-xr-x. 11 root root 4.0K Feb 9 17:46 share
drwxr-xr-x. 4 root root 4.0K Feb 9 17:46 lib64
drwxr-xr-x. 2 root root 4.0K Feb 9 17:46 sbin
drwxr-xr-x 4 root root 4.0K Feb 9 17:29 modsecurity
drwxr-xr-x 7 diradmin diradmin 4.0K Feb 9 17:26 directadmin
drw------- 6 root root 4.0K Feb 9 17:07 csf
drwxr-xr-x 4 root root 4.0K Feb 9 17:07 man
drwxr-xr-x 3 root root 4.0K Feb 9 16:58 php
drwxr-xr-x 7 root root 4.0K Feb 9 16:52 icu
dr-x–x–x 2 apache apache 4.0K Feb 9 16:45 safe-bin
drwxr-xr-x. 13 root root 4.0K Feb 9 16:05 …
drwxr-xr-x 5 root root 4.0K Dec 3 13:59 awstats-7.6
drwxr-xr-x. 2 root root 4.0K Nov 5 16:38 games
drwxr-xr-x. 2 root root 4.0K Nov 5 16:38 libexec
drwxr-xr-x. 2 root root 4.0K Nov 5 16:38 src
drwxr-xr-x 4 root wheel 4.0K Apr 16 2006 sysbk
[root@vps cwaf]# ls -thal
total 128K
drwxrwxr-x 5 cwaf_plugin cwaf_plugin 4.0K Feb 20 17:07 tmp
drwxrwxr-x 4 cwaf_plugin cwaf_plugin 4.0K Feb 13 18:14 etc
drwxrwxr-x 4 cwaf_plugin cwaf_plugin 4.0K Feb 13 18:04 scripts
-rw-r–r-- 1 cwaf_plugin cwaf_plugin 540 Feb 13 18:04 INFO.TXT
drwxr-xr-x 10 cwaf_plugin cwaf_plugin 4.0K Feb 9 18:01 .
lrwxrwxrwx 1 cwaf_plugin cwaf_plugin 40 Feb 9 18:01 rules → /usr/local/cwaf/tmp/rules/workdir2/rules
drwxr-xr-x. 23 root root 4.0K Feb 9 17:53 …
drwxr-xr-x 2 cwaf_plugin cwaf_plugin 4.0K Feb 9 17:33 run
drwxr-xr-x 2 cwaf_plugin cwaf_plugin 4.0K Feb 9 17:33 conf
lrwxrwxrwx 1 cwaf_plugin cwaf_plugin 13 Feb 9 17:33 logs → /var/log/CWAF
-rw-rw-r-- 1 cwaf_plugin cwaf_plugin 4.9K Jan 23 11:53 vars.sh
drwxrwxr-x 8 cwaf_plugin cwaf_plugin 4.0K Jan 23 11:52 web
drwxrwxr-x 2 cwaf_plugin cwaf_plugin 4.0K Jan 23 11:52 bin
drwxrwxr-x 3 cwaf_plugin cwaf_plugin 4.0K Jan 23 11:52 modules
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 5.3K Jan 23 11:52 setup.sh
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 66K Jan 23 11:52 installer.sh
[root@vps scripts]# ls -thal
total 112K
—s–x–x 1 root cwaf_plugin 8.9K Feb 13 18:04 suid
drwxrwxr-x 4 cwaf_plugin cwaf_plugin 4.0K Feb 13 18:04 .
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 2.0K Feb 13 18:04 suid.c
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 16K Feb 13 18:04 updater.pl
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 6.6K Feb 13 18:04 update-client.pl
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 2.5K Feb 13 18:04 uninstall_perl_mods.pl
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 8.6K Feb 13 18:04 uninstall_cwaf.sh
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 1.1K Feb 13 18:04 fix_excludes.pl
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 1.7K Feb 13 18:04 fix_exclude_cache.pl
—x------ 1 cwaf_plugin cwaf_plugin 9.5K Feb 13 18:04 cwaf-wrapper.pl
-rwxrwxr-x 1 cwaf_plugin cwaf_plugin 19K Feb 13 18:04 cwaf-cli.pl
drwxr-xr-x 10 cwaf_plugin cwaf_plugin 4.0K Feb 9 18:01 …
drwxrwxr-x 2 cwaf_plugin cwaf_plugin 4.0K Jan 23 11:52 cwatch
drwxrwxr-x 2 cwaf_plugin cwaf_plugin 4.0K Jan 23 11:52 EasyApache
We reproduced this issue and got the same results. WebMin works with root privileges, but DirectAdmin doesn’t.
As cwaf works with DirectAdmin, please change in /usr/local/cwaf/modules/CPAN/lib/Comodo/CWAF/Main.pm
string
‘sub is_webmin() { return (-e ‘/etc/webmin/miniserv.conf’); }’ on miniserv1.conf
It will fix the issue but this module could be rewritten in cwaf-client updates.
Thank you for research.
Your fix work 
I transfer this fix to directadmin support.
Have a nice day.