Apache TraceEnable关闭与测试方法
2015-11-10 13:09
411 查看
系统环境:
OS: RHEL5.6_x64
Apache: httpd-2.2.11
关闭方法:
在主配置文件httpd.conf中添加配置:
TraceEnable off
可以直接配置在ServerRoot参数下面。
测试方法:
通过telnet到HTTP的某个服务端口,进行测试,如下描述(红色为你要输入的部分)。
关闭前测试会返回200 OK:
[root@web001 ~]$ telnet xxx.xxx.xxx.xxx 80
Trying xxx.xxx.xxx.xxx...
Connected to xxx.xxx.xxx.xxx (xxx.xxx.xxx.xxx).
Escape character is '^]'.
TRACE / HTTP/1.0
X-Test:abcde
HTTP/1.1 200 OK
Date: Wed, 18 Jul 2012 06:49:19 GMT
Server: Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_jk/1.2.28
Connection: close
Content-Type: message/http
TRACE / HTTP/1.0
X-Test: abcde
Connection closed by foreign host.
关闭后测试会返回405 Method Not Allowed:
[root@web001 ~]$ telnet xxx.xxx.xxx.xxx 80
Trying xxx.xxx.xxx.xxx...
Connected to xxx.xxx.xxx.xxx (xxx.xxx.xxx.xxx).
Escape character is '^]'.
TRACE / HTTP/1.0
X-Test:abcde
HTTP/1.1 405 Method Not Allowed
Date: Wed, 18 Jul 2012 06:50:05 GMT
Server: Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_jk/1.2.28
Allow:
Content-Length: 223
Connection: close
Content-Type: text/html; charset=iso-8859-1
X-Pad: avoid browser bug
Connection closed by foreign host.
OS: RHEL5.6_x64
Apache: httpd-2.2.11
关闭方法:
在主配置文件httpd.conf中添加配置:
TraceEnable off
可以直接配置在ServerRoot参数下面。
测试方法:
通过telnet到HTTP的某个服务端口,进行测试,如下描述(红色为你要输入的部分)。
关闭前测试会返回200 OK:
[root@web001 ~]$ telnet xxx.xxx.xxx.xxx 80
Trying xxx.xxx.xxx.xxx...
Connected to xxx.xxx.xxx.xxx (xxx.xxx.xxx.xxx).
Escape character is '^]'.
TRACE / HTTP/1.0
X-Test:abcde
HTTP/1.1 200 OK
Date: Wed, 18 Jul 2012 06:49:19 GMT
Server: Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_jk/1.2.28
Connection: close
Content-Type: message/http
TRACE / HTTP/1.0
X-Test: abcde
Connection closed by foreign host.
关闭后测试会返回405 Method Not Allowed:
[root@web001 ~]$ telnet xxx.xxx.xxx.xxx 80
Trying xxx.xxx.xxx.xxx...
Connected to xxx.xxx.xxx.xxx (xxx.xxx.xxx.xxx).
Escape character is '^]'.
TRACE / HTTP/1.0
X-Test:abcde
HTTP/1.1 405 Method Not Allowed
Date: Wed, 18 Jul 2012 06:50:05 GMT
Server: Apache/2.2.11 (Unix) mod_ssl/2.2.11 OpenSSL/0.9.8e-fips-rhel5 DAV/2 mod_jk/1.2.28
Allow:
Content-Length: 223
Connection: close
Content-Type: text/html; charset=iso-8859-1
X-Pad: avoid browser bug
Method Not Allowed
The requested method TRACE is not allowed for the URL /.Connection closed by foreign host.
相关文章推荐
- Apache Isis 1.4.0 发布,领域驱动开发框架
- Linux快速构建apache web服务器
- Awstats处理多apache日志
- 安装perl模块小窍门
- PHP+Apache在Windows 9x下的安装和配置
- Apache服务器配置全攻略
- Apache Web让JSP“动”起来
- Linux Apache+MySQL+PHP
- 建立Apache+PHP+MySQL数据库驱动的动态网站
- apache 环境下 php 的配置注意事项
- 在RedHat下安装apache jserv 1.1.2方法
- windows8.1下Apache+Php+MySQL配置步骤
- windows中PHP5.2.14以及apache2.2.16安装配置方法第1/2页
- 在Windows XP下安装Apache+MySQL+PHP环境
- 解析阿里云ubuntu12.04环境下配置Apache+PHP+PHPmyadmin+MYsql
- apache rewrite防盗链三例
- Apache 配置详解(最好的APACHE配置教程)
- Apache+php+mysql在windows下的安装与配置(图文)第1/2页
- apache rewrite_module模块使用教程
- Apache rewrite重写规则的常见应用