# Another 403 error....yes...I've googled it too.

## maddphunkster

I installed apache the other week and with the default configuration files I could type http://127.0.0.1 and see the default apache page just fine. I changed the listen port to 9090

(Adelphia does'nt seem to like ports 80 and 8080)  and had a friend see if he could publicly access my site and again, everything worked fine.

After accidently wiping my system and rebuilding it again(with ACCEPT_KEYORDS="~x86") I once again emerged apache (2.0.48-r4, same as before), left the configs at default with the exception of the listen port.

Now I get a 403 Forbidden error.

I've looked at the permissions, chown'ed apache:apache /var/www/, tried changing the lines in commonapache2.conf from

```

<Directory />

  Options -All -Multiviews

  AllowOverride None

   <IfModule mod_auth.c>

    Order deny,allow

    Deny from all

    </IfModule>

</Directory>

```

to

```

<Directory />

  Options All Multiviews Indexes 

  AllowOverride None

    Order allow,deny

    Allow from all

</Directory>

```

, changed the apache entry in /etc/passwd to point to /var/www /var/www/localhost /var/www/localhost/htdocs and back,

placed a simple index.html in htdocs/

among other things, nothing seems to work

I don't think I should have to do this since it worked fine without changing the config files before. anyone have any advice?? 

For someone who's linux certified, I would think I could figure this out on my own, but i can't[/code]

----------

## Telamon

Are you getting any errors in /etc/apache2/logs/error_log ?  You might also want to check the other <Directory> blocks, as they may have their own Allow/Deny settings.  Look in /etc/apache2/conf/commonapache2.conf for the  "Directory /var/www/localhost/htdocs" block and make sure you have Allow from all set.

----------

## maddphunkster

the 

<Document /var/www/localhost/htdocs> block has the Allow from all directive. 

mabe this has something to do with it...

```

ldd -r /usr/lib/apache2/modules/mod_access.so

        linux-gate.so.1 =>  (0xffffe000)

        libpthread.so.0 => /lib/libpthread.so.0 (0x40011000)

        libc.so.6 => /lib/libc.so.6 (0x40022000)

        /lib/ld-linux.so.2 => /lib/ld-linux.so.2 (0x80000000)

undefined symbol: ap_log_rerror (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: ap_satisfies  (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: ap_some_auth_required (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_strerror  (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_pstrdup   (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: ap_get_remote_host    (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_table_get (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: ap_hook_access_checker        (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_palloc    (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_ipsubnet_create   (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_array_push        (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_ipsubnet_test     (/usr/lib/apache2/modules/mod_access.so)

undefined symbol: apr_array_make        (/usr/lib/apache2/modules/mod_access.so)

```

Here also is an excerpt from the logs

Mon Mar 15 14:27:09 2004] [error] [client 127.0.0.1] (13)Permission denied: access to / denied

[Mon Mar 15 14:27:10 2004] [error] [client 127.0.0.1] (13)Permission denied: access to / denied

[Mon Mar 15 14:27:11 2004] [error] [client 127.0.0.1] (13)Permission denied: access to / denied

[Mon Mar 15 14:27:12 2004] [error] [client 127.0.0.1] (13)Permission denied: access to / denied

[Mon Mar 15 14:27:12 2004] [error] [client 127.0.0.1] (13)Permission denied: access to / denied

[Mon Mar 15 14:38:07 2004] [notice] caught SIGTERM, shutting down

[Mon Mar 15 14:38:09 2004] [notice] Digest: generating secret for digest authentication ...

[Mon Mar 15 14:38:09 2004] [notice] Digest: done

[Mon Mar 15 14:38:10 2004] [notice] Apache/2.0.48 (Gentoo/Linux) configured -- resuming normal operations

[Mon Mar 15 14:38:46 2004] [notice] caught SIGTERM, shutting down

[Mon Mar 15 14:38:48 2004] [notice] Digest: generating secret for digest authentication ...

[Mon Mar 15 14:38:48 2004] [notice] Digest: done

[Mon Mar 15 14:38:49 2004] [notice] Apache/2.0.48 (Gentoo/Linux) configured -- resuming normal operations

[Mon Mar 15 14:38:50 2004] [error] [client 192.168.1.1] (13)Permission denied: access to / denied, referer: http://maddphunkster.doesntexist.org/

[Mon Mar 15 14:39:22 2004] [error] [client 192.168.1.1] (13)Permission denied: access to / denied, referer: http://maddphunkster.doesntexist.org/

[Mon Mar 15 14:40:33 2004] [error] [client 192.168.1.1] (13)Permission denied: access to / denied, referer: http://maddphunkster.doesntexist.org/

[Mon Mar 15 14:42:22 2004] [notice] caught SIGTERM, shutting down

[Mon Mar 15 14:42:24 2004] [notice] Digest: generating secret for digest authentication ...

[Mon Mar 15 14:42:24 2004] [notice] Digest: done

[Mon Mar 15 14:42:25 2004] [notice] Apache/2.0.48 (Gentoo/Linux) configured -- resuming normal operations

[Mon Mar 15 14:42:26 2004] [error] [client 192.168.1.1] (13)Permission denied: access to / denied, referer: http://maddphunkster.doesntexist.org/

[Mon Mar 15 14:44:14 2004] [error] [client 192.168.1.1] (13)Permission denied: access to / denied, referer: http://maddphunkster.doesntexist.org/

[Mon Mar 15 14:45:27 2004] [error] [client 127.0.0.1] (13)Permission denied: access to /index.html denied

[Mon Mar 15 14:45:27 2004] [error] [client 127.0.0.1] (13)Permission denied: access to /favicon.ico denied

[Mon Mar 15 14:46:12 2004] [error] [client 127.0.0.1] (13)Permission denied: access to /server_info denied

[Mon Mar 15 15:31:33 2004] [notice] caught SIGTERM, shutting down

----------

## uraes

in apache2.conf .. what is value after DocumentRoot ?

----------

## maddphunkster

it says

DocumentRoot /var/www/localhost/htdocs

I've chown'ed it to apache:apache and back

I've made it world readable(rwxr-xr-x), so any user should be able to read the files. I've removed the apache index.html and link to the docs and placed a simple index.html in that folder, made sure it  was world readable.

here's the configs if anyone would care to look at them

### /etc/apache2/conf/apache2.conf

### $Id: apache2.conf,v 1.1 2004/01/13 01:23:23 robbat2 Exp $

###

### Main Configuration Section

### You really shouldn't change these settings unless you're a guru

###

ServerRoot /usr/lib/apache2

ServerName localhost

#LockFile /etc/apache2/apache2.lock

PidFile /var/run/apache2.pid

ErrorLog logs/error_log

LogLevel debug

DocumentRoot /var/www/localhost/htdocs

### Dynamic Shared Object (DSO) Support

### 

### You should always leave these three, as they are needed for normal use.

### mod_access (Order, Allow, etc..)

### mod_log_config (Transferlog, etc..)

### mod_mime (AddType, etc...)

###

LoadModule access_module                 modules/mod_access.so

LoadModule auth_module                   modules/mod_auth.so

LoadModule auth_anon_module              modules/mod_auth_anon.so

LoadModule auth_dbm_module               modules/mod_auth_dbm.so

LoadModule auth_digest_module            modules/mod_auth_digest.so

LoadModule include_module                modules/mod_include.so

LoadModule log_config_module             modules/mod_log_config.so

LoadModule env_module                    modules/mod_env.so

LoadModule mime_magic_module             modules/mod_mime_magic.so

LoadModule cern_meta_module              modules/mod_cern_meta.so

LoadModule expires_module                modules/mod_expires.so

LoadModule headers_module                modules/mod_headers.so

LoadModule usertrack_module              modules/mod_usertrack.so

LoadModule unique_id_module              modules/mod_unique_id.so

LoadModule setenvif_module               modules/mod_setenvif.so

LoadModule proxy_module                  modules/mod_proxy.so

LoadModule proxy_connect_module          modules/mod_proxy_connect.so

LoadModule proxy_ftp_module              modules/mod_proxy_ftp.so

LoadModule proxy_http_module	         modules/mod_proxy_http.so

LoadModule mime_module                   modules/mod_mime.so

LoadModule status_module                 modules/mod_status.so

LoadModule autoindex_module              modules/mod_autoindex.so

LoadModule asis_module                   modules/mod_asis.so

LoadModule info_module                   modules/mod_info.so

LoadModule cgi_module                    modules/mod_cgi.so

LoadModule cgid_module                   modules/mod_cgid.so

LoadModule vhost_alias_module	         modules/mod_vhost_alias.so

LoadModule negotiation_module            modules/mod_negotiation.so

LoadModule dir_module                    modules/mod_dir.so

LoadModule imap_module                   modules/mod_imap.so

LoadModule actions_module                modules/mod_actions.so

LoadModule speling_module                modules/mod_speling.so

LoadModule userdir_module                modules/mod_userdir.so

LoadModule alias_module                  modules/mod_alias.so

LoadModule rewrite_module                modules/mod_rewrite.so

###

### New Modules for 2.0 (some are experimental)

###

LoadModule file_cache_module             modules/mod_file_cache.so

LoadModule echo_module                   modules/mod_echo.so

LoadModule charset_lite_module           modules/mod_charset_lite.so

LoadModule cache_module                  modules/mod_cache.so

LoadModule disk_cache_module             modules/mod_disk_cache.so

LoadModule mem_cache_module              modules/mod_mem_cache.so

LoadModule ext_filter_module             modules/mod_ext_filter.so

LoadModule case_filter_module            modules/mod_case_filter.so

LoadModule case_filter_in_module         modules/mod_case_filter_in.so

LoadModule deflate_module                modules/mod_deflate.so

#LoadModule optional_hook_export_module   modules/mod_optional_hook_export.so

#LoadModule optional_hook_import_module   modules/mod_optional_hook_import.so

#LoadModule optional_fn_import_module     modules/mod_optional_fn_import.so

#LoadModule optional_fn_export_module     modules/mod_optional_fn_export.so

#LoadModule bucketeer_module              modules/mod_bucketeer.so

LoadModule logio_module                  modules/mod_logio.so

###

### Global Configuration

###

# Splitting up apache2.conf into two files makes it easier to support

# multiple configurations on the same serer.  In commonapache2.conf

# you keep directives that apply to all implementations and in this

# file you keep server-specific directives.  While we don't yet have

# multiple configurations out-of-the-box, this allows us to do that

# in the future easily.  (PERLPROXIED *ahem*)

#

# For Apache2 we load all conf files in conf/modules.d

Include conf/modules.d/*.conf

Include conf/commonapache2.conf

###

### IP Address/Port

###

#BindAddress *

Listen 9090

###

### Log configuration Section

###

<IfModule mod_log_config.c>

#Single logfile with access, agent and referer information

#This is the default, if vlogs are not defined for the main server

CustomLog logs/access_log combined env=!VLOG

#If VLOG is defined in conf/vhosts/vhosts.conf, we use this entry

#CustomLog "|/usr/sbin/apache2splitlogfile" vhost env=VLOG

</IfModule>

###

### Virtual Hosts 

###

# We include different templates for Virtual Hosting. Have a look in the 

# vhosts directory and modify to suit your needs.

#Include conf/vhosts/vhosts.conf

#Include conf/vhosts/dynamic-vhosts.conf

#Include conf/vhosts/virtual-homepages.conf

###

### Performance settings Section

###

#

# Timeout: The number of seconds before receives and sends time out.

#

Timeout 300

#

# KeepAlive: Whether or not to allow persistent connections (more than

# one request per connection). Set to "Off" to deactivate.

#

KeepAlive On

#

# MaxKeepAliveRequests: The maximum number of requests to allow

# during a persistent connection. Set to 0 to allow an unlimited amount.

# We recommend you leave this number high, for maximum performance.

#

MaxKeepAliveRequests 100

#

# KeepAliveTimeout: Number of seconds to wait for the next request from the

# same client on the same connection.

#

KeepAliveTimeout 15

# prefork MPM [THIS IS THE DEFAULT]

# StartServers: number of server processes to start

# MinSpareServers: minimum number of server processes which are kept spare

# MaxSpareServers: maximum number of server processes which are kept spare

# MaxClients: maximum number of server processes allowed to start

# MaxRequestsPerChild: maximum number of requests a server process serves

<IfModule prefork.c>

StartServers         5

MinSpareServers      5

MaxSpareServers     10

MaxClients         150

MaxRequestsPerChild  0

</IfModule>

# worker MPM

# StartServers: initial number of server processes to start

# MaxClients: maximum number of simultaneous client connections

# MinSpareThreads: minimum number of worker threads which are kept spare

# MaxSpareThreads: maximum number of worker threads which are kept spare

# ThreadsPerChild: constant number of worker threads in each server process

# MaxRequestsPerChild: maximum number of requests a server process serves

<IfModule worker.c>

StartServers         2

MaxClients         150

MinSpareThreads     25

MaxSpareThreads     75

ThreadsPerChild     25

MaxRequestsPerChild  0

</IfModule>

# perchild MPM

# NumServers: constant number of server processes

# StartThreads: initial number of worker threads in each server process

# MinSpareThreads: minimum number of worker threads which are kept spare

# MaxSpareThreads: maximum number of worker threads which are kept spare

# MaxThreadsPerChild: maximum number of worker threads in each server process

# MaxRequestsPerChild: maximum number of connections per server process

<IfModule perchild.c>

NumServers           5

StartThreads         5

MinSpareThreads      5

MaxSpareThreads     10

MaxThreadsPerChild  20

MaxRequestsPerChild  0

</IfModule>

##################################

#/etc/apache2/conf/commonapache2.conf

User apache

Group apache

ServerAdmin root@localhost

#DocumentRoot /var/www/localhost/htdocs

<Directory />

  Options -All -Multiviews

  AllowOverride None

   <IfModule mod_access.c>

    Order deny,allow

    Deny from all

  </IfModule>

</Directory>

<IfModule mod_userdir.c>

    UserDir public_html

</IfModule>

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

AccessFileName .htaccess

<IfModule mod_access.c>

<Files ~ "^\.ht">

    Order allow,deny

    Deny from all

</Files>

</IfModule>

#CacheNegotiatedDocs

UseCanonicalName On

<IfModule mod_mime.c>

    TypesConfig conf/mime.types

</IfModule>

DefaultType text/plain

<IfModule mod_mime_magic.c>

    MIMEMagicFile conf/magic

</IfModule>

HostnameLookups Off

EnableMMAP on

<IfModule mod_log_config.c>

LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined

LogFormat "%h %l %u %t \"%r\" %>s %b" common

LogFormat "%{Referer}i -> %U" referer

LogFormat "%{User-agent}i" agent

LogFormat "%v %h %l %u %t \"%r\" %>s %b %T" script

LogFormat "%v %h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" VLOG=%{VLOG}e" vhost

    <IfModule mod_logio.c>

        # You need to enable mod_logio.c to use %I and %O

        LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio

    </IfModule>

</IfModule>

ServerTokens Full

ServerSignature On

<IfModule mod_alias.c>

    Alias /icons/ /var/www/localhost/icons/

    Alias /doc /usr/share/doc

    ScriptAlias /cgi-bin/ /var/www/localhost/cgi-bin/

    ScriptAlias /protected-cgi-bin/ /var/www/localhost/protected-cgi-bin/

    ScriptAliasMatch ^/~([^/]*)/cgi-bin/(.*) /home/$1/public_html/cgi-bin/$2

    <IfModule mod_perl.c>

	#Provide two aliases to the same cgi-bin directory,

	#to see the effects of the 2 different mod_perl modes

	#for Apache::Registry Mode

	Alias /perl/ /var/www/localhost/perl/

	#for Apache::Perlrun Mode

	Alias /cgi-perl/ /var/www/localhost/perl/

    </IfModule>

</IfModule>

<IfModule mod_autoindex.c>

    AddIconByEncoding (CMP,/icons/compressed.png) x-compress x-gzip

    AddIconByType (TXT,/icons/text.png) text/*

    AddIconByType (IMG,/icons/image2.png) image/*

    AddIconByType (SND,/icons/sound2.png) audio/*

    AddIconByType (VID,/icons/movie.png) video/*

    AddIcon /icons/binary.gif .bin .exe

    AddIcon /icons/binhex.gif .hqx

    AddIcon /icons/tar.gif .tar

    AddIcon /icons/world2.gif .wrl .wrl.gz .vrml .vrm .iv

    AddIcon /icons/compressed.gif .Z .z .tgz .gz .zip .bz2

    AddIcon /icons/a.gif .ps .ai .eps

    AddIcon /icons/layout.gif .html .shtml .htm .pdf

    AddIcon /icons/text.gif .txt

    AddIcon /icons/c.gif .c

    AddIcon /icons/p.gif .pl .py .php .php3

    AddIcon /icons/f.gif .for

    AddIcon /icons/dvi.gif .dvi

    AddIcon /icons/uuencoded.gif .uu

    AddIcon /icons/script.gif .conf .sh .shar .csh .ksh .tcl

    AddIcon /icons/tex.gif .tex

    AddIcon /icons/bomb.gif core

    AddIcon /icons/back.gif ..

    AddIcon /icons/hand.right.gif README

    AddIcon /icons/folder.gif ^^DIRECTORY^^

    AddIcon /icons/blank.gif ^^BLANKICON^^

    DefaultIcon /icons/unknown.gif

hort description after a file in

    ReadmeName README.html

    HeaderName HEADER.html

    IndexIgnore .??* *~ *# HEADER* RCS CVS *,v *,t

</IfModule>

<IfModule mod_mime.c>

    AddEncoding x-compress Z

    AddEncoding x-gzip gz tgz

    AddLanguage ca .ca

    AddLanguage cz .cz

    AddLanguage da .dk

    AddLanguage de .de

    AddLanguage el .el

    AddLanguage en .en

    AddLanguage es .es

    AddLanguage et .ee

    AddLanguage fr .fr

    AddLanguage he .he

    AddLanguage hr .hr

    AddLanguage it .it

    AddLanguage ja .ja

    AddLanguage ko .ko

    AddLanguage kr .kr

    AddLanguage ltz .ltz

    AddLanguage ltz .lu

    AddLanguage nl .nl

    AddLanguage nn .nn

    AddLanguage no .no

    AddLanguage pl .po

    AddLanguage pt-br .pt-br

    AddLanguage pt .pt

    AddLanguage ru .ru

    AddLanguage sv .se

    AddLanguage tw .tw

    AddLanguage zh-tw .tw

    AddDefaultCharset ISO-8859-1

    <IfModule mod_negotiation.c>

        LanguagePriority en fr de es it da nl et el ja kr no pl pt pt-br ru ltz ca sv tw

    </IfModule>

    <IfModule mod_negotiation.c>

        ForceLanguagePriority Prefer Fallback

    </IfModule>

    AddCharset ISO-8859-1  .iso8859-1  .latin1

    AddCharset ISO-8859-2  .iso8859-2  .latin2 .cen

    AddCharset ISO-8859-3  .iso8859-3  .latin3

    AddCharset ISO-8859-4  .iso8859-4  .latin4

    AddCharset ISO-8859-5  .iso8859-5  .latin5 .cyr .iso-ru

    AddCharset ISO-8859-6  .iso8859-6  .latin6 .arb

    AddCharset ISO-8859-7  .iso8859-7  .latin7 .grk

    AddCharset ISO-8859-8  .iso8859-8  .latin8 .heb

    AddCharset ISO-8859-9  .iso8859-9  .latin9 .trk

    AddCharset ISO-2022-JP .iso2022-jp .jis

    AddCharset ISO-2022-KR .iso2022-kr .kis

    AddCharset ISO-2022-CN .iso2022-cn .cis

    AddCharset Big5        .Big5       .big5

    AddCharset WINDOWS-1251 .cp-1251   .win-1251

    AddCharset CP866       .cp866

    AddCharset KOI8-r      .koi8-r .koi8-ru

    AddCharset KOI8-ru     .koi8-uk .ua

    AddCharset ISO-10646-UCS-2 .ucs2

    AddCharset ISO-10646-UCS-4 .ucs4

    AddCharset UTF-8       .utf8

    AddCharset GB2312      .gb2312 .gb

    AddCharset utf-7       .utf7

    AddCharset utf-8       .utf8

    AddCharset big5        .big5 .b5

    AddCharset EUC-TW      .euc-tw

    AddCharset EUC-JP      .euc-jp

    AddCharset EUC-KR      .euc-kr

    AddCharset shift_jis   .sjis

    AddType application/x-tar .tgz

    AddType image/x-icon .ico

    AddHandler cgi-script .cgi

    AddHandler type-map var

    AddType text/html .shtml

    AddOutputFilter INCLUDES .shtml

    AddHandler imap-file map

</IfModule>

#Action media/type /cgi-script/location

#Action handler-name /cgi-script/location

#    Alias /error/ "/var/www/localhost/error/"

#

#   <Directory "/var/www/localhost/error">

#       AllowOverride None

#        Options IncludesNoExec

#        AddOutputFilter Includes html

#        AddHandler type-map var

#        Order allow,deny

#        Allow from all

#        LanguagePriority en es de fr sv

#        ForceLanguagePriority Prefer Fallback

#   </Directory>

#

#    ErrorDocument 400 /error/HTTP_BAD_REQUEST.html.var

#    ErrorDocument 401 /error/HTTP_UNAUTHORIZED.html.var

#    ErrorDocument 403 /error/HTTP_FORBIDDEN.html.var

#    ErrorDocument 404 /error/HTTP_NOT_FOUND.html.var

#    ErrorDocument 405 /error/HTTP_METHOD_NOT_ALLOWED.html.var

#    ErrorDocument 408 /error/HTTP_REQUEST_TIME_OUT.html.var

#    ErrorDocument 410 /error/HTTP_GONE.html.var

#    ErrorDocument 411 /error/HTTP_LENGTH_REQUIRED.html.var

#    ErrorDocument 412 /error/HTTP_PRECONDITION_FAILED.html.var

#    ErrorDocument 413 /error/HTTP_REQUEST_ENTITY_TOO_LARGE.html.var

#    ErrorDocument 414 /error/HTTP_REQUEST_URI_TOO_LARGE.html.var

#    ErrorDocument 415 /error/HTTP_SERVICE_UNAVAILABLE.html.var

#    ErrorDocument 500 /error/HTTP_INTERNAL_SERVER_ERROR.html.var

#    ErrorDocument 501 /error/HTTP_NOT_IMPLEMENTED.html.var

#    ErrorDocument 502 /error/HTTP_BAD_GATEWAY.html.var

#    ErrorDocument 503 /error/HTTP_SERVICE_UNAVAILABLE.html.var

#    ErrorDocument 506 /error/HTTP_VARIANT_ALSO_VARIES.html.var

###

### Customizable error responses come in three flavors:

###

#    1) plain text

#ErrorDocument 500 "The server made a boo boo."

#

#    2) local redirects

#ErrorDocument 404 /missing.html

#  to redirect to local URL /missing.html

#ErrorDocument 404 "/cgi-bin/missing_handler.pl"

#  N.B.: You can redirect to a script or a document using server-side-includes.

#

#    3) external redirects

#ErrorDocument 402 http://www.example.com/subscription_info.html

#  N.B.: Many of the environment variables associated with the original

#  request will *not* be available to such a script.

<Location /manual>

    Options Multiviews

    ErrorDocument 404 "The document you requested has not been installed on your system."

</Location>

<IfModule mod_setenvif.c>

    BrowserMatch "Mozilla/2" nokeepalive

    BrowserMatch "MSIE 4\.0b2;" nokeepalive downgrade-1.0 force-response-1.0

    BrowserMatch "RealPlayer 4\.0" force-response-1.0

    BrowserMatch "Java/1\.0" force-response-1.0

    BrowserMatch "JDK/1\.0" force-response-1.0

    BrowserMatch "Microsoft Data Access Internet Publishing Provider" redirect-carefully

    BrowserMatch "^WebDrive" redirect-carefully

    BrowserMatch "^gnome-vfs" redirect-carefully

    BrowserMatch "^WebDAVFS" redirect-carefully

</IfModule>

<IfModule mod_status.c>

    <Location /server-status>

        SetHandler server-status

        <IfModule mod_access.c>

          Order deny,allow

          Deny from all

          allow from 127.0.0.1

          #Allow from .your_domain.com

        </IfModule>

    </Location>

#ExtendedStatus On

</IfModule>

<IfModule mod_info.c>

    <Location /server-info>

        SetHandler server-info

        <IfModule mod_access.c>

        Order deny,allow

        Deny from all

        allow from 127.0.0.1

        #Allow from .your_domain.com

        </IfModule>

    </Location>

</IfModule>

<IfModule mod_perl.c>

    <Location /perl-status>

        SetHandler perl-script

        PerlResponseHandler ModPerl::Status

        <IfModule mod_access.c>

          Order deny,allow

          Deny from all

          Allow from 127.0.0.1

        </IfModule>

    </Location>

</IfModule>

#<IfModule mod_proxy.c>

#    ProxyRequests On

#    <Directory proxy:*>

#        Order deny,allow

#        Deny from all

#        Allow from .your_domain.com

#    </Directory>

    #

    # Enable/disable the handling of HTTP/1.1 "Via:" headers.

    # ("Full" adds the server version; "Block" removes all outgoing Via: headers)

    # Set to one of: Off | On | Full | Block

    #

#   ProxyVia On

    #

    # To enable the cache as well, edit and uncomment the following lines:

    # (no caching without CacheRoot)

    #

#    <IfModule mod_disk_cache.c>

#      CacheRoot "/var/cache/apache2"

#      CacheSize 5

#      CacheGcInterval 4

#      CacheMaxExpire 24

#      CacheLastModifiedFactor 0.1

#      CacheDefaultExpire 1

#      #NoCache a-domain.com another-domain.edu joes.garage-sale.com

#    </IfModule>

#</IfModule>

# End of proxy directives.

<IfModule mod_include.c>

#    XBitHack on

</IfModule>

###

### The mod_deflate module provides the DEFLATE output filter.

### It allows output from your server to be compressed before

### being sent to the client over the network.

###

<IfModule mod_deflate.c>

    <Directory "/var/www/localhost/htdocs/manual">

      AddOutputFilterByType DEFLATE text/html

    </Directory>

    # DeflateFilterNote - Set a note to report on compression ratio

#   DeflateFilterNote deflate_ratio

#    LogFormat "%h %l %u %t \"%r\" %>s %b mod_deflate: %{deflate_ratio}n pct." common_with_deflate_info

#    CustomLog logs/deflate.log common_with_deflate_info

#    # Set the Deflate window size (1-15)

#    DeflateWindowSize 10

#    # Set the Deflate Memory Level (1-9)

#    DeflateMemLevel 6

</IfModule>

<Directory /var/www/localhost/htdocs>

    Options All MultiViews

    AllowOverride All

    <IfModule mod_access.c>

      Order allow,deny

      Allow from all 

    </IfModule>

</Directory>

<Directory /var/www/localhost/perl>

    AllowOverride All

    Options -Indexes FollowSymLinks MultiViews ExecCGI

    <IfModule mod_access.c>

      Order allow,deny

      Allow from all

    </IfModule>

</Directory>

<IfModule mod_cgid.c>

#    Scriptsock /cgisock

</IfModule>

<Directory /var/www/localhost/cgi-bin>

    AllowOverride All

    Options ExecCGI

    <IfModule mod_access.c>

      Order allow,deny

      Allow from all

    </IfModule>

</Directory>

<Directory /var/www/localhost/protected-cgi-bin>

    AllowOverride All

    Options ExecCGI

    <IfModule mod_access.c>

      Order deny,allow

      Deny from all

      Allow from 127.0.0.1

      #allow from .your_domain.com

    </IfModule>

</Directory>

#<Directory /home/*/public_html>

#    AllowOverride FileInfo AuthConfig Limit

#    Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec

#    <Limit GET POST OPTIONS PROPFIND>

#        Order allow,deny

#        Allow from all

#    </Limit>

#    <LimitExcept GET POST OPTIONS PROPFIND>

#        Order deny,allow

#        Deny from all

#    </LimitExcept>

#</Directory>

<Directory /home/*/public_html>

    AllowOverride All

    Options MultiViews -Indexes Includes FollowSymLinks

    <IfModule mod_access.c>

      Order allow,deny

      Allow from all

    </IfModule>

</Directory>

<Directory /home/*/public_html/cgi-bin>

     Options +ExecCGI -Includes -Indexes

     SetHandler cgi-script

</Directory>

<IfModule mod_perl.c>

    <Directory /home/*/public_html/perl>

        SetHandler perl-script

        PerlResponseHandler ModPerl::PerlRun

        Options -Indexes ExecCGI

        PerlSendHeader On

    </Directory>

</IfModule>

<Directory /var/www/localhost/icons>

    Options -Indexes MultiViews

    AllowOverride None

    <IfModule mod_access.c>

      Order allow,deny

      Allow from all

    </IfModule>

</Directory>

<Directory /usr/share/doc>

    <IfModule mod_deflate.c>

      AddOutputFilterByType DEFLATE text/html

    </IfModule>

    Options Indexes FollowSymLinks

    <IfModule mod_access.c>

      Order deny,allow

      Deny from all

      Allow from 127.0.0.1

      #allow from .your_domain.com

    </IfModule>

</Directory>

<Location /index.shtml>

    Options +Includes

</Location>

<Location /index.html>

    Options All

</Location>

<IfModule mod_perl.c>

    PerlModule Apache2::ModPerl::Registry

    #set Apache::Registry Mode for /perl Alias

    <Location /perl/*.pl>

        SetHandler perl-script

        PerlResponseHandler ModPerl::Registry

        Options -Indexes ExecCGI

        PerlSendHeader On

    </Location>

    #set Apache::PerlRun Mode for /cgi-perl Alias

    <Location /cgi-perl/*.pl>

        SetHandler perl-script

        PerlResponseHandler ModPerl::PerlRun

        Options -Indexes ExecCGI

        PerlSendHeader On

    </Location>

</IfModule>

<IfModule mod_alias.c>

AliasMatch ^/manual(?:/(?:de|en|fr|ja|ko|ru))?(/.*)?$ "/var/www/localhost/htdocs/manual/$1"

</IfModule>

<Directory "/var/www/localhost/htdocs/manual">

    Options Indexes

    AllowOverride None

    Order allow,deny

    Allow from all

    <Files *.html>

        SetHandler type-map

    </Files>

    SetEnvIf Request_URI ^/manual/de/ prefer-language=de

    SetEnvIf Request_URI ^/manual/en/ prefer-language=en

    SetEnvIf Request_URI ^/manual/fr/ prefer-language=fr

    SetEnvIf Request_URI ^/manual/ja/ prefer-language=ja

    SetEnvIf Request_URI ^/manual/ko/ prefer-language=ko

    SetEnvIf Request_URI ^/manual/ru/ prefer-language=ru

    RedirectMatch 301 ^/manual(?:/(de|en|fr|ja|ko|ru)){2,}(/.*)?$ /manual/$1$2

</Directory>

####################################

I have to be missing something really simple....or mabe not....

----------

## b0x

I wish you'd got an answer from this as i'm having exactly the same problem with no obvious, or unobvious solution (and i've built a few complex apache 1.3.x installations in my time)

----------

## bone

See the following section below, from your config file:

[code]

<Directory /var/www/localhost/htdocs>

Options All MultiViews

AllowOverride All

<IfModule mod_access.c>

Order allow,deny

Allow from all

</IfModule>

</Directory>

[/code]

You not being able to access this directory (DocumentRoot) makes me think that mod_access is not loaded. If it were, then it would also process the Order and Allow settings that are specified in its section. I would say this is the best place to start. Let me know if this does not help you and I will see what else we missed.

----------

## lepek

I have  a similar problem (sorry my english, it's not my first laguage). When I put the site into /var/www/localhost/htdocs it works just fine, but when I create a virtual host it's keep telling me 403 FORBIDDEN bla bla. The permissions of both directories in commonapache.conf are the same...

----------

## sanrou

 *bone wrote:*   

> See the following section below, from your config file:
> 
> ```
> 
> <Directory /var/www/localhost/htdocs>
> ...

 

How do I check to see if the mod_access is loaded, then?

----------

## +Kardboard+

I've gotten the same problem.  My mod_access is loaded though.  What's up?  Do you just use chmod to change permissions?  What command do I invoke to set the directory (and it's children folders) viewable to the whole freakin' world?  Sorry, I'm a n00b.   :Smile: 

----------

## +Kardboard+

Oh!!  Never mind, I fixed it.   :Very Happy:  :Very Happy:  :Very Happy: 

```

# chmod a=rwx /var/www

# chmod a=rwx /var/www/localhost

# chmod a=rwx /var/www/localhost/htdocs
```

That should do something.  :p  I guess "chmod -r a=rwx /var/www" would have worked too eh?  XDXD

----------

## castrik

im also getting this kind of error. does anybody have any ideas? No matter what i set the permissions as, i get a 403.

----------

