24 Sep

[php安全]php pathinfo设置

by 碟舞飞扬 at 10:15 under 服务器类 不指定 | |
Tags: ,
由于脚本编写时出错导致可能存在pathinfo漏洞,请所有lnmp用户检查一下php的pathinfo设置!!!

编辑/usr/local/webserver/php/etc/php.ini 文件,搜索 cgi.fix_pathinfo ,如果cgi.fix_pathinfo 该行为 ; cgi.fix_pathinfo=0 请修改为 cgi.fix_pathinfo=0
或直接执行:sed -i 's/; cgi.fix_pathinfo=0/cgi.fix_pathinfo=0/g' /usr/local/webserver/php/etc/php.ini

再执行:/usr/local/webserver/php/sbin/php-fpm restart 重启php-fpm

如果是cgi.fix_pathinfo=0则没问题,不需要修改。
请各位lnmp(linux+nginx+mysql+php)用户检查一下,防止pathinfo漏洞给网站或服务器带来安全隐患。
发表评论
表情
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
emotemotemotemotemot
打开HTML
打开UBB
打开表情
隐藏
记住我
昵称   密码   游客无需密码
网址   电邮   [注册]