highlander985
highlander985

Reputation: 41

Forbidden error when accessing wamp from local network

Okay now, this problem has been driving me crazy for a week! I hope we will find a solution together.

I am trying to configure my wamp server to run on a local network (be accessable from a local network). Specifically, I want to access a project saved in the /www folder from another computer using a local area connection. I am using Windows 7 for my wamp server. However, when I run "192.168.178.3:8080" from the other computer I get the following error:

Forbidden: You don't have permissions to access / on this server.

I am running wamp on port 8080 (port 80 is used by IIS);
My local IP address is 192.168.178.3

I'll try to explain the things I have done so far...

Changed the following in httpd.conf:

Listen 192.168.178.3:8080

<Directory />
  Options FollowSymLinks
  AllowOverride None
  Order deny,allow
  Allow from all
</Directory>

<Directory "c:/wamp/www/">
#
# Possible values for the Options directive are "None", "All",
# or any combination of:
#   Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
#
# Note that "MultiViews" must be named *explicitly* --- "Options All"
# doesn't give it to you.
#
# The Options directive is both complicated and important.  Please see
# http://httpd.apache.org/docs/2.4/mod/core.html#options
# for more information.
#
Options Indexes FollowSymLinks

#
# AllowOverride controls what directives may be placed in .htaccess files.
# It can be "All", "None", or any combination of the keywords:
#   Options FileInfo AuthConfig Limit
#
AllowOverride All
#
# Controls who can get stuff from this server.
#
# Online --> Require all granted

#   onlineoffline tag - don't remove
Order Deny,Allow
Allow from all
Allow from 127.0.0.1

Require local

</Directory>

<Directory "c:/wamp/www/project">
   allow from all
</Directory>

<Directory "cgi-bin">
  AllowOverride None
  Options None
  Order allow,deny
  Allow from all
</Directory>

Also, I inserted the following lines in http-vhosts.conf:

<VirtualHost 192.168.178:8080>
    DocumentRoot "C:/wamp/www/project"
</VirtualHost>

I've restarted everything and put the server Online but still get the same error.

Any help or suggestion would be appreciated.

Thank you in advance!

Upvotes: 1

Views: 13738

Answers (1)

highlander985
highlander985

Reputation: 41

I actually managed to solve my problem.

The port 8080 seemed to be causing problems (weird right). So I reinstalled wamp and only made the following changes in the httpd.conf (using port 8070):

Listen 192.168.178.3:8070

<Directory "cgi-bin">
    AllowOverride None
    Options None
    Order allow,deny
    Allow from all
</Directory>

Also, I had to add an exception of this port in the Kaspersky firewall, as well as configuring the router to forward the port. That solved it.

Upvotes: 3

Related Questions