2

I'm trying to connect to phpMyAdmin which is running on my CentOS server from my pc with the following phpMyAdmin.conf:

<Directory /usr/share/phpMyAdmin/>
   AddDefaultCharset UTF-8

   <IfModule mod_authz_core.c>
     # Apache 2.4
     <RequireAny>
       Require ip 127.0.0.1
       Require ip 192.168.5.100
       Require ip 192.168.5.120
       Require ip ::1
     </RequireAny>
   </IfModule>
   <IfModule !mod_authz_core.c>
     # Apache 2.2
     Order Deny,Allow
     Deny from All
     Allow from 127.0.0.1
     Allow from 192.168.5.100
     Allow from 192.168.5.120
     Allow from ::1
   </IfModule>
</Directory>

<Directory /usr/share/phpMyAdmin/setup/>
   <IfModule mod_authz_core.c>
     # Apache 2.4
     <RequireAny>
       Require ip 127.0.0.1
       Require ip 192.168.5.100
       Require ip 192.168.5.120
       Require ip ::1


    Require ip 192.168.5.120
       Require ip ::1
     </RequireAny>
   </IfModule>
   <IfModule !mod_authz_core.c>
     # Apache 2.2
     Order Deny,Allow
     Deny from All
     Allow from 127.0.0.1
     Allow from 192.168.5.100
     Allow from 192.168.5.120
     Allow from ::1
   </IfModule>
</Directory>

# These directories do not require access over HTTP - taken from the original
# phpMyAdmin upstream tarball
#
<Directory /usr/share/phpMyAdmin/libraries/>
    Order Deny,Allow
    Deny from All
    Allow from None
</Directory>

<Directory /usr/share/phpMyAdmin/setup/lib/>
    Order Deny,Allow
    Deny from All
    Allow from None
</Directory>

<Directory /usr/share/phpMyAdmin/setup/frames/>
    Order Deny,Allow
    Deny from All
    Allow from None
</Directory>

# This configuration prevents mod_security at phpMyAdmin directories from
# filtering SQL etc.  This may break your mod_security implementation.
#

I have no permission to access it from the server itself or from my PC on the same network and get the error message:

> Forbidden
> 
> You don't have permission to access /phpmyadmin/ on this server.

When I try to connect. What should I do to access phpMyAdmin?

Edit: My logs are full of this:

[Wed Jan 30 19:39:40.248831 2019] [authz_core:error] [pid 578] [client 192.168.5.100:51511] AH01630: client denied by server configuration: /usr/share/phpMyAdmin/

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.