Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

XAMPP - Access to the requested object is only available from the local network

When I try to access an phpMyAdmin of xampp in another pc using ip address I get this error:

Access forbidden!

New XAMPP security concept:

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

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

I was searching for the solution and found a bunch of suggestions like modifying httpd-xampp.conf file.

1) Option was to modify <LocationMatch> block like this:

<LocationMatch "^/(?i(?:xampp|security|licenses|phpmyadmin|webalizer|server-status|server-info))">
    Order deny,allow
    Allow from all
    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</LocationMatch>

The problem is that my httpd-xampp.conf file does not contain such a block, but if I try to add it to the end of the file I still get the same error.

2) Option was to modify <Directory "C:/xampp/phpMyAdmin"> as following:

<Directory "C:/xampp/phpMyAdmin">
    AllowOverride AuthConfig Limit
    Order allow,deny
    Allow from all
    Require all granted
    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</Directory>

Or

<Directory "C:/xampp/phpMyAdmin">
    AllowOverride AuthConfig Limit
    Order allow,deny
    Allow from all
    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</Directory>

Or

<Directory "C:/xampp/phpMyAdmin">
    AllowOverride AuthConfig Limit
    Require all granted
    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</Directory>

This didn't solve the problem either. Still getting same error.

P.S. I am restarting Apache after each change!

Could someone see what I could be missing?

like image 938
Ignas Damunskis Avatar asked Apr 25 '17 15:04

Ignas Damunskis


People also ask

How do I fix access forbidden in xampp?

Although XAMPP error 403 can be annoying, it's easy to solve whether you're using Windows, macOS, or Linux. All you have to do is edit the XAMPP httpd-xampp. conf file to ensure that everyone has access to phpMyAdmin. Then the 403 error should disappear right away.

Where is Httpd-xampp conf?

Re: httpd-xampp. conf. Please look inside your \xampp\apache\conf\extra folder.


1 Answers

I just fixed it ! Please go to :

<Directory "C:/xampp/phpMyAdmin">
    AllowOverride AuthConfig
    Require local
    ErrorDocument 403 /error/XAMPP_FORBIDDEN.html.var
</Directory>

and change all the contents as below:

<Directory "C:/xampp/phpMyAdmin">
     AllowOverride AuthConfig Limit
     Order allow,deny
     Require all granted
     Allow from all
</Directory>
like image 128
Yi Hsuan Wang Avatar answered Sep 17 '22 02:09

Yi Hsuan Wang