2016-04-29 89 views
0

因此,我在nginx机器上安装了Magento 2.0.5 CE。一切顺利。我现在可以登录到管理面板并浏览。Magento2安装破坏会话并注销

但是,一旦我访问http://example.com/setup,它会将我重定向到../setup/index.php/session/unlogin,显示消息“访问被拒绝”。并破坏当前会话,迫使我重新登录管理面板。即使清除所有缓存后,重新启动nginx并重复上述步骤,也会发生同样的情况。现在有点困在这里..

2016/04/29 06:41:47 [error] 4808#0: *188 FastCGI sent in stderr: "Access to the script '/var/www/magento/setup/index.php/session/unlogin' has been denied (see security.limit_extensions)" while reading response header from upstream, client: *.*.*.246, server: example.com, request: "GET /setup/index.php/session/unlogin HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "www.example.com" 
2016/04/29 06:41:48 [error] 4808#0: *188 FastCGI sent in stderr: "Access to the script '/var/www/magento/setup/index.php/session/unlogin' has been denied (see security.limit_extensions)" while reading response header from upstream, client: *.*.*.246, server: example.com, request: "GET /setup/index.php/session/unlogin HTTP/1.1", upstream: "fastcgi://unix:/var/run/php5-fpm.sock:", host: "www.example.com" 

试图改变/etc/php5/fpm/pool.d/www.conf从

; security.limit_extensions = .php .php3 .php4 .php5 

security.limit_extensions = .php .php3 .php4 .php5 

没有运气:(

帮助!

回答

0

更改

cgi.fix_pathinfo=0 

cgi.fix_pathinfo=1 

在php.ini中解决的问题。不过,我会避免使用此选项,并等待任何人有更安全的解决方案。