Access forbidden while accessing xampp on LAN

Problems with the Windows version of XAMPP, questions, comments, and anything related.

Access forbidden while accessing xampp on LAN

Postby divyasmk » 30. March 2011 10:51

I have installed xampp-win32-1.7.4-VC6 on windows.
I can access it by on my machine(using http://localhost).
But it showing the error while accessing it through other machine which are locally connected.
The error like following.....

Access forbidden!

New XAMPP security concept:

Access to the requested directory is only available from the local network.

This setting can be configured in the file "httpd-xampp.conf".

If you think this is a server error, please contact the webmaster.
Error 403
192.x.x.x
3/30/2011 2:51:51 PM
Apache/2.2.17 (Win32) mod_ssl/2.2.17 OpenSSL/0.9.8o PHP/5.3.4 mod_perl/2.0.4 Perl/v5.10.1


I had used http://192.x.x.x to access the xampp from other machine.

If anybody knows please help me.
divyasmk
 
Posts: 1
Joined: 30. March 2011 10:40

Re: Access forbidden while accessing xampp on LAN

Postby Sharley » 01. April 2011 01:41

Open \xampp\apache\conf\extra\httpd-xampp.conf in your notepad or similar text editor and find this section and change it by adding 192.168.0.0/16 so it looks like this
Code: Select all
#
# New XAMPP security concept
#
<LocationMatch "^/(?i:(?:xampp|security|licenses|phpmyadmin|webalizer|server-status|server-info))">
    Order deny,allow
    Deny from all
    Allow from 127.0.0.0/8 192.168.0.0/16
    ErrorDocument 403 /error/HTTP_XAMPP_FORBIDDEN.html.var
</LocationMatch>
Save the file and then restart Apache and try once again to access.

Also check in the \xampp\apache\conf\httpd.conf file that the Listen directive looks like this
Code: Select all
Listen 80
or
Listen *:80
It should not say Listen 127.0.0.1:80 and again if you have to make any changes then save the file and restart Apache.

Note - always make a backup of any file that you may have to change before you make any changes so you have a fall back file if requited.
User avatar
Sharley
AF Moderator
 
Posts: 3316
Joined: 03. October 2008 05:10
Location: Yeppoon, Australia Time Zone: GMT/UTC+10
Operating System: Win 7 Pro 32bit/XP Pro SP3


Return to XAMPP for Windows

Who is online

Users browsing this forum: No registered users and 52 guests