Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 73954 - apache2 (2.0.52-r1) doesn't treat index.php as a directory index
Summary: apache2 (2.0.52-r1) doesn't treat index.php as a directory index
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Apache Team - Bugzilla Reports
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-12-09 15:36 UTC by Rafal Peisert
Modified: 2005-01-30 11:18 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Rafal Peisert 2004-12-09 15:36:39 UTC
With the default order here in the commonapache2.conf:
<IfModule mod_dir.c>
    DirectoryIndex index.html index.html.var index.php index.php3 index.shtml index.cgi index.pl index.htm Default.htm default.htm
</IfModule>
and only index.php in the DocumentRoot if one tries to load http://www.example.dom/ apache2 throws 403 Forbidden. http://www.example.dom/index.php works. Changing the order in the IfModule directive so index.php is first solves the problem.

Reproducible: Always
Steps to Reproduce:
1. emerge apache2 & mod_php
2. empty DocumentRoot and create index.php with some content
3. Try to load http://your.domain.dom/

Actual Results:  
403 Forbidden

Expected Results:  
loading of index.php as the directory index

Portage 2.0.51-r3 (default-linux/x86/2004.3, gcc-3.3.4, glibc-2.3.4.20040808-r1,
2.4.26-gentoo-r13 i686)
=================================================================
System uname: 2.4.26-gentoo-r13 i686 AMD Sempron(tm)   2400+
Gentoo Base System version 1.4.16
Autoconf: sys-devel/autoconf-2.59-r5
Automake: sys-devel/automake-1.8.5-r1
Binutils: sys-devel/binutils-2.15.90.0.1.1-r3
Headers:  sys-kernel/linux-headers-2.4.21-r1
Libtools: sys-devel/libtool-1.5.2-r7
ACCEPT_KEYWORDS="x86"
AUTOCLEAN="yes"
CFLAGS="-O3 -march=athlon-xp -fomit-frame-pointer -pipe"
CHOST="i686-pc-linux-gnu"
COMPILER=""
CONFIG_PROTECT="/etc /usr/kde/2/share/config /usr/kde/3/share/config
/usr/share/config /var/bind /var/qmail/control"
CONFIG_PROTECT_MASK="/etc/gconf /etc/terminfo /etc/env.d"
CXXFLAGS="-O3 -march=athlon-xp -fomit-frame-pointer -pipe"
DISTDIR="/usr/portage/distfiles"
FEATURES="autoaddcvs autoconfig ccache distlocks sandbox sfperms"
GENTOO_MIRRORS="http://gentoo.osuosl.org
http://distro.ibiblio.org/pub/Linux/distributions/gentoo"
MAKEOPTS="-j2"
PKGDIR="/usr/portage/packages"
PORTAGE_TMPDIR="/var/tmp"
PORTDIR="/usr/portage"
PORTDIR_OVERLAY=""
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="3dnow acl acpi apache2 apm arts avi bash-completion berkdb bitmap-fonts
bzlib crypt cscope cups encode f77 fam foomaticdb fortran ftp gd gif gnome gtk
gtk2 imap imlib innodb ipv6 jpeg kde kerberos krb4 libg++ libwww mad maildir
memlimit mikmod mmap mmx motif mpeg mpi mysql mysqli ncurses nls oggvorbis
opengl oss pam pcntl pcre pdflib perl php pic pie png posix python quicktime
readline sasl sdl shared sharedmem simplexml slang sockets spell sse ssl svga
tcpd tiff tokenizer truetype vhosts x86 xml xml2 xmlrpc xmms xv zlib"
Comment 1 Robin Johnson archtester Gentoo Infrastructure gentoo-dev Security 2004-12-18 19:25:10 UTC
is '-D PHP4' set in your /etc/conf.d/apache2 ?
Comment 2 Rafal Peisert 2004-12-19 07:05:06 UTC
Yes it is. As I wrote, adding 'index.php' to the url worked - and by 'worked' I meant it was loaded and properly interpreted by mod_php. It just wasn't recognised as a directory index.
Comment 3 Benedikt Böhm (RETIRED) gentoo-dev 2005-01-30 07:35:40 UTC
i cannot confirm this. it works perfectly with my apache installation
please try remerging apache or updating to 2.0.52-r3
Comment 4 Christian Parpart (RETIRED) gentoo-dev 2005-01-30 10:48:04 UTC
*heh* This MUST NO be a PHP / autoindex issue.

Have you defined right permissions for this directory?
Have a look at your error logfile - and yet, make sure, you've apache-2.0.52-r3 emerged.
Comment 5 Rafal Peisert 2005-01-30 11:18:13 UTC
Well I'll be damned, I couldn't reproduce it now. The logs from December are long gone and forgotten so no help from there either. Well, maybe it was happening because of solar flares or something ;) Thanks for your time, anyway.