You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by Number <nu...@soez.be> on 2006/09/15 11:31:59 UTC

[users@httpd] Options Indexes work not like i would like ..

Hello,

For begining, i would like to excuse myself, I'm french so excuse my english 
language..

I have installed Apache on Fedora Cora 5 and i think that the indexes option 
was strange ..

I have this :

________________________________________
[...]
DocumentRoot "/var/www/html/number/www"
[...]
<Directory "/">
Options -Indexes FolloSymLinks
AllowOverride None
</Directory>
[...]
<Directory "/var/www/html/number/www">
Options -Indexes FollowSymLinks
AllowOverride AuthConfig
Order allow,deny
Allow from all
</Directory>
[...]
Alias /icons/ "/var/www/icons/"

<Directory "/var/www/icons/">
Options Indexes Multiview
AllowOverride None
Order allow,deny
Allow from all
</Directory>
[...]
NameVirtualHost *:80

<VirtualHost *:80>
Options Indexes
ServerName monserveur.be
ServerAlias files.monserveur.be
DocumentRoot /var/www/html/number/files/
</VirtualHost>
[...]
________________________________________

If you want to see my httpd.conf you can here : 
http://number.number.ath.cx/httpd.conf

Like you see on my example above :
I have setting - Index for the root directory ("/") and for the DocumentRoot 
("/var/www/html/number/www/")
And for files.serveur.be i have setting Options Indexes..

The Indexes Options work for icons alias, but not for the files vhost..
I can try to edit the httpd.conf, no one of my test work..

But they don't work.. I have a Frbidden You don't have permission to access  / 
on this server

And on error.log :
Direcroty index forbidden by Options directive : /var/www/html/number/files/, 
referer number.ath.cx

P.S : You can't try with files.number.ath.cx because they work..
Because it's not the same serveur, i try to make a NEW installed more properly 
with a other pc on local.

Thanks for your reply

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


Re: [users@httpd] Options Indexes work not like i would like ..

Posted by Joshua Slive <jo...@slive.ca>.
On 9/15/06, Number <nu...@soez.be> wrote:
> Thanks for your reply, but i have a few questions
>
> Like you say, i can't have a "+/-" options with a non "+/-" options
> Either  i use "+/-" for both, or i don't use .
> I'm right ?

Yes.

>
> And after you say, any options wasn't listed un Options was null, none, or
> false ?

What I mean is that
Options Indexes
will turn off all options except indexes, while
Options +Indexes
will leave all the options set as they were, but add the Indexes option.

Bonne chance!

Joshua.

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


Re: [users@httpd] Options Indexes work not like i would like ..

Posted by Number <nu...@soez.be>.
Thanks for your reply, but i have a few questions

Like you say, i can't have a "+/-" options with a non "+/-" options
Either  i use "+/-" for both, or i don't use . 
I'm right ?

And after you say, any options wasn't listed un Options was null, none, or 
false ?

(Excuse for this questions, but i'm understand more when it's in french ;-))

For the rest i understand.. Directory was more important than VirtualHost..
It's better for security .

And icons/ directory work because it a directory and not a virtualhost..

Many thanks ;-)

It's will be solved :-)


Le vendredi 15 septembre 2006 15:01, Joshua Slive a écrit :
> A few problems here.  First, never mix "+/-" and non-"+/-" options
> together on the same Options line.  It doesn't make any sense since
> having any non-"+/-" options automatically indicates that options are
> reset to None before adding the listed options.  See:
> http://httpd.apache.org/docs/2.2/mod/core.html#options
>
> More importantly for your problem, the order that directives are
> applied is not the same as the config-file order.  It is specified
> here:
> http://httpd.apache.org/docs/2.2/sections.html#mergin
> In particular, options inside <Directory> sections are applied after
> Options specified in a bare <VirtualHost> section.  So to get what you
> want, put the following inside the <VirtualHost> section:
> <Directory /var/www/html/number/files>
> Options Indexes
> </Directory>.
>
> Joshua.

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


Re: [users@httpd] Options Indexes work not like i would like ..

Posted by Joshua Slive <jo...@slive.ca>.
On 9/15/06, Number <nu...@soez.be> wrote:

> ________________________________________
> [...]
> DocumentRoot "/var/www/html/number/www"
> [...]
> <Directory "/">
> Options -Indexes FolloSymLinks
> AllowOverride None
> </Directory>
> [...]
> <Directory "/var/www/html/number/www">
> Options -Indexes FollowSymLinks
> AllowOverride AuthConfig
> Order allow,deny
> Allow from all
> </Directory>
> [...]
> Alias /icons/ "/var/www/icons/"
>
> <Directory "/var/www/icons/">
> Options Indexes Multiview
> AllowOverride None
> Order allow,deny
> Allow from all
> </Directory>
> [...]
> NameVirtualHost *:80
>
> <VirtualHost *:80>
> Options Indexes
> ServerName monserveur.be
> ServerAlias files.monserveur.be
> DocumentRoot /var/www/html/number/files/
> </VirtualHost>
> [...]

A few problems here.  First, never mix "+/-" and non-"+/-" options
together on the same Options line.  It doesn't make any sense since
having any non-"+/-" options automatically indicates that options are
reset to None before adding the listed options.  See:
http://httpd.apache.org/docs/2.2/mod/core.html#options

More importantly for your problem, the order that directives are
applied is not the same as the config-file order.  It is specified
here:
http://httpd.apache.org/docs/2.2/sections.html#mergin
In particular, options inside <Directory> sections are applied after
Options specified in a bare <VirtualHost> section.  So to get what you
want, put the following inside the <VirtualHost> section:
<Directory /var/www/html/number/files>
Options Indexes
</Directory>.

Joshua.

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