can't get htaccess in Apache to work
This is driving me nuts. No matter what I do, what changes I make in
httpd.conf, how I make .htaccess, I can't get directory security to
work.
I have folder:
/var/www/html/msa
In it I have the file .htaccess which contains:
AuthUserFile /var/www/html/msa/htpasswd
AuthName "Enter Password"
require valid-user
AuthType Basic
Satisfy any
To create the htpasswd file, from the command prompt in the folder I
did:
$ htpasswd -c ./htpasswd username
I put the password in twice as prompted.
I Web browse to that dir, and I don't get challenged for a password.
In my httpd.conf, I have these lines: (with some stuff in between each
section, but they are in this order)
<Directory />
Options FollowSymLinks
#AllowOverride AuthConfig
AllowOverride None
</Directory>
<Directory "/var/www/html">
Options Indexes FollowSymLinks
#AllowOverride None <--If I use this line, I can't access ANY
folder
AllowOverride AuthConfig
Order allow,deny
Allow from all
</Directory>
AccessFileName .htaccess
<Files ~ "^\.ht">
Order allow,deny
Deny from all
Satisfy All
</Files>
I can't find any other sections that might be related.
At this point, I can't even remember all the different ways I've tried
editing these lines. And only two results will occur: No change and I
can access the directory in question unchallenged, or I'm not allowed
to access ANY folder.
Any suggestions what in the world I'm doing wrong?
Thanks!
Liam
|