apache httpd开启webdav服务,客户端通过PUT请求上传文件。
当上传文件的文件名大于9个汉字时,可以成功;反之失败。
客户端是同一份代码,两者的唯一区别就是文件名,文件内容是一样的。
这可能是什么原因?怎么修改服务器配置?
客户端分别抓包如下:
-------------------------------------------------
成功:
Packet #15, Direction: Out, Time:18:01:15.859144, Size: 481
Ethernet II
Destination MAC: 00:1D:0F:45:21:72
Source MAC: 00:1B:77:7C:AA:68
Ethertype: 0x0800 (2048) - IP
IP
IP version: 0x04 (4)
Header length: 0x05 (5) - 20 bytes
Differentiated Services Field: 0x00 (0)
Differentiated Services Code Point: 000000 - Default
ECN-ECT: 0
ECN-CE: 0
Total length: 0x01D3 (467)
ID: 0x1046 (4166)
Flags
Don't fragment bit: 1 - Don't fragment
More fragments bit: 0 - Last fragment
Fragment offset: 0x0000 (0)
Time to live: 0x80 (128)
Protocol: 0x06 (6) - TCP
Checksum: 0xF286 (62086) - correct
Source IP: 192.168.1.143
Destination IP: 221.226.86.--
IP Options: None
TCP
Source port: 6760
Destination port: 80
Sequence: 0x20116883 (538011779)
Acknowledgement: 0x7BF31A16 (2079529494)
Header length: 0x05 (5) - 20 bytes
Flags: PSH ACK
URG: 0
ACK: 1
PSH: 1
RST: 0
SYN: 0
FIN: 0
Window: 0x10E0 (4320)
Checksum: 0xE31D (58141) - correct
Urgent Pointer: 0x0000 (0)
TCP Options: None
HTTP
Version: HTTP/1.1
Method: PUT
URI: /webdav/%e6%b2%88%e9%98%b3%e5%85%ac%e5%ae%89%e8%ae%be%e8%ae%a1%e8%81%94%e7%bb%9c%e4%bc%9a%e4%bc%9a%e8%ae%ae%e7%ba%aa%e8%a6%81%ef%bc%9awap%e9%83%a8%e5%88%862012-08-24.txt
Content-Language: en-us
Accept-Language: zh-cn, en-us;q=0.2
Translate: f
Range: bytes=0-
Content-Range: bytes 0-6/7
Authorization: Basic
Username: zyb
Password: ---
Host: 221.226.86.--
Content-Length: 6
Expect: 100-continue
Connection: Close
-------------------------------------------------
失败:
Packet #10, Direction: Out, Time:18:01:09.989518, Size: 326
Ethernet II
Destination MAC: 00:1D:0F:45:21:72
Source MAC: 00:1B:77:7C:AA:68
Ethertype: 0x0800 (2048) - IP
IP
IP version: 0x04 (4)
Header length: 0x05 (5) - 20 bytes
Differentiated Services Field: 0x00 (0)
Differentiated Services Code Point: 000000 - Default
ECN-ECT: 0
ECN-CE: 0
Total length: 0x0138 (312)
ID: 0x1036 (4150)
Flags
Don't fragment bit: 1 - Don't fragment
More fragments bit: 0 - Last fragment
Fragment offset: 0x0000 (0)
Time to live: 0x80 (128)
Protocol: 0x06 (6) - TCP
Checksum: 0xF331 (62257) - correct
Source IP: 192.168.1.143
Destination IP: 221.226.86.--
IP Options: None
TCP
Source port: 6759
Destination port: 80
Sequence: 0x196F968D (426743437)
Acknowledgement: 0x94635EBB (2489540283)
Header length: 0x05 (5) - 20 bytes
Flags: PSH ACK
URG: 0
ACK: 1
PSH: 1
RST: 0
SYN: 0
FIN: 0
Window: 0x10E0 (4320)
Checksum: 0x5039 (20537) - correct
Urgent Pointer: 0x0000 (0)
TCP Options: None
HTTP
Version: HTTP/1.1
Method: PUT
URI: /webdav/my.txt
Content-Language: en-us
Accept-Language: zh-cn, en-us;q=0.2
Translate: f
Range: bytes=0-
Content-Range: bytes 0-6/7
Authorization: Basic
Username: zyb
Password: ---
Host: 221.226.86.--
Content-Length: 6
Expect: 100-continue
Connection: Close
---------------------------------------------------
--
FROM 125.119.252.*