httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Mike Holley <mhol...@byu.edu>
Subject Re: [users@httpd] Getting .htaccess to work
Date Fri, 21 May 2004 17:41:11 GMT
On May 21, 2004, at 11:24 AM, Joshua Slive wrote:

>
> On Fri, 21 May 2004, Mike Holley wrote:
>> Here is the part of code in my virtual host file 
>> (0004_any_80_identity.byu.edu.conf) that looks for the .htaccess file 
>> in mediaFiles:
>>        <Directory /Library/WebServer/Documents/identity/mediaFiles>
>>        AllowOverride All
>>        </Directory>
>>
>> Here is the code in my .htaccess file:
>> Order Deny,Allow
>>        Deny from all
>>        Allow from 128.187
>>        Allow from byu.edu
>
>> I know that the .htaccess file is being used, a lot of commenting out 
>> a line and reloading the page; but I can't seem to get it to deny 
>> from one and allow another. It seem to only want to do one or the 
>> other. I would appreciate any help that can be given. Thanks.
>
> Note that you don't need to use .htaccess at all.  You can put the 
> same directives directly inside the relevant <Directory> section in 
> httpd.conf.
Yes I know, but it wasn't working that way either, so I tried the 
.htaccess way, hoping it would be different.

> You haven't been very clear about exactly what happens with the above 
> configuration.  Is everyone allowed in?  Is nobody allowed in?
Right now every one can download from the site. What I have found, and 
forgot to mention, is that I can't modify the default. If the order 
directive say the default is allow, then it seems to ignore the "deny 
from all" line. Whereas if the default is deny then it ignores the 
"allow from 128.187" line. As it is now, the default is allow so 
everyone can get in, seeing that "there is no deny." (At least that is 
what I figure.)

> Let's see some entries from your access_log file showing what happens 
> when people from inside and outside 128.187 access the directory with 
> the above configuration.  And you may perhaps want to show us similar 
> entries when you only have the Deny from all, and for when you add an 
> Allow from all.
I am sorry for being so ignorant, but where is the access_log typically?


---------------------------------------------------------------------
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
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message