Password protect web directory with htpasswd on Cherokee
Posted
by
wdkrnls
on Server Fault
See other posts from Server Fault
or by wdkrnls
Published on 2011-02-07T05:26:21Z
Indexed on
2011/02/07
7:27 UTC
Read the original article
Hit count: 520
I have a directory on my Cherokee webserver that I am trying to password protect so that when I try to enter it from a web browser, I get a pop up demanding username and password. Needless to say I am getting stuck.
I have created the .htaccess file with:
AuthUserFile /srv/http/protected
AuthGroupFile /dev/null
AuthName "Protected Stuff"
AuthType Basic
Require valid-user
And I used the apache-tools' htpasswd command:
htpasswd -c .htpasswd wdkrnls
I configured Cherokee with a behavior rule on the /protected directory which requires htpasswd authentication and restarted. I get Error 405 Method Not Allowed
whenever I navigate there in a directory.
What more do I need to do? Thanks for your help.
© Server Fault or respective owner