在Apache2上的access_log中找到十六进制字符(\ xHH)

时间:2015-05-19 07:16:16

标签: apache logging hex

在我的RHEL 3中安装带有CGI模块的Apache2后,在他的 logs / acces_log 中记录特殊的十六进制字符。为什么会出现?

.two_boxes{
    margin: auto;
    width: 100%;
    max-width: 940px;
    height: 448px;
    padding-top: 0px;   
    position: relative;
}

.sun{
    background-image: url('sun_banner.jpg');
    background-repeat:no-repeat;
    background-size:100%;
    width: 48%;
    max-width: 458px; 
    height: 100%;
    max-height: 448px;
    display: inline-block; 
}

.overlay{   
    background:rgba(0,0,0,.75);
    text-align:center;
    width: 100%;
    height: 100%;
    z-index: 100; 
    opacity:0;
    -webkit-transition: opacity .25s ease;
    -moz-transition: opacity .25s ease;
}

.sun:hover .overlay{
    opacity:1;
}

1 个答案:

答案 0 :(得分:0)

问题在于非法客户请愿。服务器没问题。它发送了一个不正确的 Content-Lenght 标头,这会导致日志过载缓冲。例如,在此标头请求中,内容长度为1000,但正确内容长度为500.

Date: Thu, 28 May 2015 06:25:43 GMT
Server: Apache/2.0.52 (Red Hat)
Last-Modified: Mon, 26 Jan 2015 16:18:38 GMT
ETag: "115446-e4e1c0-7da57380"
Accept-Ranges: bytes
Content-Length: 1000
Connection: close
Content-Type: text/plain; charset=UTF-8

这引起 Apache2 服务器读取缓冲区字节,而 acces_log 出现十六进制字符 \ xHH