If you don’t want to implement complex user administration with authorization components for you application then you can simple protect your secret functions by using .htpasswd file.
I am just giving an example for admin function.
htpasswd -c /etc/httpd/.htpasswd admin
chown apache.root /etc/httpd/.htpasswd
chmod 644 /etc/httpd/.htpasswd
Add the below lines on your apache virtual host configuration
Now you required user name and password to access your admin function.
Latest posts by Tapas Mishra (see all)
- Working with Docker – II - December 16, 2016
- Working with Docker – I - November 28, 2016
- How to work with Chef using Oracle VirtualBox and Vagrant on a Windows host – Part II - November 30, 2014