(...)
Is there a better way to do this using CWP ?
Create a file /usr/local/cwpsrv/conf/security.conf with the following content:
#...
satisfy any;
allow 192.168.1.1/24;
allow 127.0.0.1;
deny all;
auth_basic "Restricted access";
auth_basic_user_file conf/ht_passwd;
Choose yours IP adresses, and/or define additional authentication on cwpsrv.
Create a file '/usr/local/cwpsrv/conf/ht_passwd' with your passwords:
# /usr/local/apache/bin/htpasswd /usr/local/cwpsrv/conf/ht_passwd
In file '/usr/local/cwpsrv/conf/cwp_services.conf', change your directive to:
location /pma {
root /usr/local/cwpsrv/var/services;
index index.html index.htm index.php;
include /usr/local/cwpsrv/conf/security.conf;
(...)
}
...and restart cwp on the panel, or with the command:
# /scripts/restart_cwpsrv
Regards,
Netino