打开APP
userphoto
未登录

开通VIP,畅享免费电子书等14项超值服

开通VIP
关闭 php X-Powered-By 信息

在请求头的时候可以看到 X-Powered-By 字样,为了 安全可以去掉.看你的需要了

linux 下 执行 curl -head http://blog.wumashi.com 会显示出如下信息

HTTP/1.1 200 OK
Date: Tue, 26 Oct 2010 02:53:56 GMT
Server: Apache
X-Powered-By: PHP/5.2.1
Vary: Accept-Encoding
Connection: close
Content-Type: text/html; charset=UTF-8 

要去掉  X-Powered-By: PHP/5.2.1
则修改 php.ini 文件 设置 expose_php = Off

说明  
Decides whether PHP may expose the fact that it is installed on the server
 (e.g. by adding its signature to the Web server header).  It is no security
 threat in any way, but it makes it possible to determine whether you use PHP
on your server or not.

决定服务器上是否暴露安装有PHP,
(例如:把这些信息加到Web服务器头响应)。这是不安全的。
但能确定你的服务器时候运行着PHP。
意思就是打开的话可以告诉其他人这台服务器可以运行PHP,但不一定安全,可以关掉

关闭输出 X-Powered-By 信息

本站仅提供存储服务,所有内容均由用户发布,如发现有害或侵权内容,请点击举报
打开APP,阅读全文并永久保存 查看更多类似文章
猜你喜欢
类似文章
【热】打开小程序,算一算2024你的财运
PHP利用获取系统信息的简单示例
使用Eclipse进行PHP的服务器端调试
php获取IP
apache、php隐藏头信息的方法
在Zend Studio中设置php server
德馨 ? 黑莓mds断网服务器
更多类似文章 >>
生活服务
热点新闻
分享 收藏 导长图 关注 下载文章
绑定账号成功
后续可登录账号畅享VIP特权!
如果VIP功能使用有故障,
可点击这里联系客服!

联系客服