[Решение] Apache 2.4 - 403 Access Forbiden

Аватар пользователя JKey

После обновления/перехода на Apache 2.4  с переносом всех конфигов - ловим 403 ошибку. 
Включаем  дебаг режим в логе, дабы узреть в чем проблемас, и видим подобные записи

[Mon Jun 01 11:43:58.998603 2015] [authz_core:debug] [pid 9398] mod_authz_core.c(802): [client Client_IP:39111] AH01626: authorization result of Require all denied: denied
[Mon Jun 01 11:43:58.998674 2015] [authz_core:debug] [pid 9398] mod_authz_core.c(802): [client Client_IP:39111] AH01626: authorization result of <RequireAny>: denied
[Mon Jun 01 11:43:58.998683 2015] [authz_core:error] [pid 9398] [client Client_IP:39111] AH01630: client denied by server configuration: /opt/debt/fis/www/fcs/tools.php
[Mon Jun 01 11:43:58.998780 2015] [authz_core:debug] [pid 9398] mod_authz_core.c(802): [client Client_IP:39111] AH01626: authorization result of Require all granted: granted
[Mon Jun 01 11:43:58.998793 2015] [authz_core:debug] [pid 9398] mod_authz_core.c(802): [client Client_IP:39111] AH01626: authorization result of <RequireAny>: granted
[Mon Jun 01 11:48:21.203852 2015] [authz_core:debug] [pid 9508] mod_authz_core.c(802): [client Client_IP:39215] AH01626: authorization result of Require all granted: granted
[Mon Jun 01 11:48:21.203914 2015] [authz_core:debug] [pid 9508] mod_authz_core.c(802): [client Client_IP:39215] AH01626: authorization result of <RequireAny>: granted
[Mon Jun 01 11:48:21.271776 2015] [authz_core:debug] [pid 9508] mod_authz_core.c(802): [client Client_IP:39215] AH01626: authorization result of Require all granted: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:48:21.271797 2015] [authz_core:debug] [pid 9508] mod_authz_core.c(802): [client Client_IP:39215] AH01626: authorization result of <RequireAny>: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:51:31.000490 2015] [authz_core:debug] [pid 9509] mod_authz_core.c(802): [client Client_IP:39248] AH01626: authorization result of Require all granted: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:51:31.000550 2015] [authz_core:debug] [pid 9509] mod_authz_core.c(802): [client Client_IP:39248] AH01626: authorization result of <RequireAny>: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:51:31.005120 2015] [authz_core:debug] [pid 9510] mod_authz_core.c(802): [client Client_IP:39249] AH01626: authorization result of Require all granted: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:51:31.005169 2015] [authz_core:debug] [pid 9510] mod_authz_core.c(802): [client Client_IP:39249] AH01626: authorization result of <RequireAny>: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:51:31.007935 2015] [authz_core:debug] [pid 9511] mod_authz_core.c(802): [client Client_IP:39250] AH01626: authorization result of Require all granted: granted, referer: http://The.Server.IP/
[Mon Jun 01 11:51:31.008001 2015] [authz_core:debug] [pid 9511] mod_authz_core.c(802): [client Client_IP:39250] AH01626: authorization result of <RequireAny>: granted, referer: http://The.Server.IP/

Все делом в том, что в версии 2.4. произошли изменения

In 2.4, such access control is done in the same way as other authorization checks, using the new module mod_authz_host. The old access control idioms should be replaced by the new authentication mechanisms, although for compatibility with old configurations, the new module mod_access_compat is provided.

Соответственно необходимо поменять директивы необходимым образом. Например вот так

Order allow, deny 

на

Require all granted 

Полный список изменений на http://httpd.apache.org/docs/2.4/upgrading.html

Тэги: 

Раздел сайта: