httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Owen Boyle <...@bourse.ch>
Subject Re: htaccess
Date Wed, 20 Mar 2002 15:56:49 GMT
alain wrote:
> 
> I don't want to protect "/" but i want to protect "/folder1"
> what do i put for :
> 
> <Directory />
>  AllowOverride ???
> </Directory>

??? = None

this will switch off Overriding in all sub-directories. Then you switch
it on again for the folder with the .htaccess file:

> <Directory /path/to/folder1>
>  AllowOverride AuthConfig 
> </Directory>

Rgds,

Owen Boyle.

PS Overriding is just a method to get directives in .htaccess files
taken into the configuration. It is not essential for password
protection. You can also put the authentication directives directly into
httpd.conf and eliminate the .htaccess files, e.g.

<Directory />
 AllowOverride None
</Directory>

<Directory /path/to/folder1>
    AuthType      Basic
    AuthName      "Restricted Area "
    AuthUserFile  /path/to/passwd/file.pwd
    require       valid-user
</Directory>

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message