Add test scenario chunked-transfer-encoding
[privoxy.git] / tests / cts / chunked-transfer-encoding / data / test35
1 <testcase>
2 <info>
3 <keywords>
4 HTTP
5 HTTP GET
6 chunked transfer encoding
7 </keywords>
8 </info>
9
10 <reply>
11 <data>
12 HTTP/1.1 200 OK\r
13 Date: Thu, 22 Jul 2010 11:22:33 GMT\r
14 Connection: keep-alive\r
15 Content-Type: text/html\r
16 Transfer-Encoding: chunked\r
17 \r
18 FE\r
19 %repeat[253 x A]%
20 \r
21 XYZ\r
22 This chunk is preceded by an invalid chunk-size
23 %repeat[1000 x Padding]%
24 \r
25 0\r
26 \r
27 </data>
28 # We only send parts of the response and then wait longer
29 # than Privoxy's socket-timeout to make sure Privoxy always
30 # forwards the same data to curl.
31 <servercmd>
32 writesize: 4000
33 writedelay: 4000
34 </servercmd>
35 </reply>
36
37 <proxy-reply>
38 <data nonewline="yes">
39 HTTP/1.1 200 OK\r
40 Date: Thu, 22 Jul 2010 11:22:33 GMT\r
41 Connection: keep-alive\r
42 Content-Type: text/html\r
43 Transfer-Encoding: chunked\r
44 \r
45 FE\r
46 %repeat[253 x A]%
47 \r
48 XYZ\r
49 This chunk is preceded by an invalid chunk-size
50 %repeat[507 x Padding]%Paddi
51 </data>
52 </proxy-reply>
53
54 <client>
55 <server>
56 http
57 </server>
58 <name>
59 Chunked transfer encoding - Invalid chunk-size. Filtering disabled.
60 </name>
61 <features>
62 proxy
63 </features>
64 <command timeout="20">
65 --raw http://%HOSTIP:%HTTPPORT/no-filter/chunked-content/%TESTNUMBER
66 </command>
67 </client>
68
69 <verify>
70 <protocol>
71 GET /no-filter/chunked-content/%TESTNUMBER HTTP/1.1\r
72 Host: %HOSTIP:%HTTPPORT\r
73 User-Agent: curl/%VERSION\r
74 Accept: */*\r
75 \r
76 </protocol>
77 <errorcode>
78 56
79 </errorcode>
80 </verify>
81 </testcase>