tests/cts: When there's lots of POST data, read it from a file
[privoxy.git] / tests / cts / client-body-tagger-https / data / test15
1 <testcase>
2 <info>
3 <keywords>
4 HTTPS
5 HTTP POST
6 client-body-tagger
7 </keywords>
8 </info>
9
10 <reply>
11 <data>
12 HTTP/1.1 200 OK
13 Content-Length: 21
14 Content-Type: text/html
15
16 Received your input.
17 </data>
18 </reply>
19
20 <proxy-reply>
21 <data>
22 HTTP/1.1 200 Connection established\r
23 \r
24 HTTP/1.1 200 OK\r
25 Content-Length: 21\r
26 Content-Type: text/html\r
27 \r
28 Received your input.
29 </data>
30 </proxyreply>
31
32 <client>
33 <server>
34 https
35 </server>
36 <name>
37 Two requests to the same URL. The second one is a POST request with an offending word but it's too large to buffer and tag so it gets to pass. (XXX: Privoxy could execute the tagger based on the data that fits into the buffer) (based on test 7)
38 </name>
39 <features>
40 proxy
41 </features>
42 <command>
43 -s --write-out '%{stderr}%{response_code}\n' --insecure https://%HOSTIP:%HTTPSPORT/%TESTNUMBER --next -d @log/post-data-%TESTNUMBER -s --write-out '%{stderr}%{response_code}\n' --insecure https://%HOSTIP:%HTTPSPORT/%TESTNUMBER
44 </command>
45 <file name="log/post-data-%TESTNUMBER">
46 blafasel%repeat[20000 x padding]%
47 </file>
48 </client>
49
50 <verify>
51 <protocol nonewline="yes">
52 GET /%TESTNUMBER HTTP/1.1\r
53 Host: %HOSTIP:%HTTPSPORT\r
54 User-Agent: curl/%VERSION\r
55 Accept: */*\r
56 \r
57 POST /%TESTNUMBER HTTP/1.1\r
58 Host: %HOSTIP:%HTTPSPORT\r
59 User-Agent: curl/%VERSION\r
60 Accept: */*\r
61 Content-Length: 140008\r
62 Content-Type: application/x-www-form-urlencoded\r
63 \r
64 blafasel%repeat[20000 x padding]%
65 </protocol>
66 <stderr>
67 200
68 200
69 </stderr>
70
71 </verify>
72 </testcase>