Trying to setup basic HTTP authentication with Apache, but it's not working. I get the directory listing and files regularly, no authentication required. I tried restarting httpd and the browsers cache.
I can't find any relevant entries in /var/log/httpd/error_log.
Any ideas?
htpasswd:
# htpasswd -c /usr/local/share/passwords username
$ ls -l /usr/local/share/passwords
-rw-r--r-- 1 root root 44 Nov 23 13:29 /usr/local/share/passwords
.htaccess:
$ cat /srv/http/test/.htaccess
AuthType Basic
AuthName "Some Stuff"
AuthUserFile /usr/local/share/passwords
Require user username
The directory:
$ ls -la /srv/http/test/
total 16
drwxr-xr-x 2 root root 4096 Nov 23 13:27 .
drwxr-xr-x 4 root root 4096 Nov 23 00:40 ..
-rw-r--r-- 1 root root 96 Nov 23 13:35 .htaccess
-rw-r--r-- 1 root root 14 Nov 23 00:40 page.html