httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joshua Slive <jsl...@gmail.com>
Subject Re: [users@httpd] Strange problem with Options +Indexes
Date Sun, 21 Aug 2005 14:39:55 GMT
On 8/21/05, Stuart Gall <stuart@otenet.gr> wrote:
> Hello,
> As I understand it <Location something>
> and <Directory something>
> are equivalent except Location refers from the Document root

That's a gross (and potentially dangerous) oversimplification.  See:
http://httpd.apache.org/docs/2.0/sections.html#file-and-web
for the true difference.

> 
> So I have apache 2.0.50 installed on Mandrake

A little bit of an old version.

> In one of my virtual hosts I have
> 
>         <Location />
>                 Allow from all
>         </Location>
> 
>         <Location /ppm/storyboard>
>                 Options +Indexes
>                 Allow from all                         **
>         </Location>
> 
> When I go to this location with a web browser I see the directory index
> but with no files UNLESS
> I also include
> 
>         <Directory /document root>
>                 Allow from all
>         </Directory>
> 
> I do not see any files listed.
> 
> Why do I need the double Allow from all ??
> Or more interestingly if access to the location is denied why dont I
> get a forbidden message instead of an empty listing ?

Interesting.  If you request the files inside the directory directly,
does it work?

I haven't tested this myself, but my guess is that mod_autoindex
(which generates the directory listings) is doing a file-level
sub-request on each entry in the directory to see if it is accessible.
 For some reason this sub-request is not processing the <Location>
sections, only the <Directory> sections.

You still can see the directory itself because the main request is
honoring the <Location> section.

---------------------------------------------------------------------
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