Debian Codegraph @

deps/curl/tests/data/test259

raw
1 <testcase>
2 <info>
3 <keywords>
4 HTTP
5 HTTP FORMPOST
6 HTTP proxy
7 HTTP proxy Digest auth
8 --proxy-anyauth
9 </keywords>
10 </info>
11 # Server-side
12 <reply>
13 # The stupid test server doesn't response anything at all until the full
14 # request has been sent, and then of course the full POST has already been
15 # sent!
16 <data>
17 HTTP/1.1 407 no, tell me who you are first
18 Date: Thu, 09 Nov 2010 14:49:00 GMT
19 Server: test-server/fake
20 Proxy-Authenticate: Digest realm="many secrets", nonce="911"
21 Content-Length: 0
22
23 </data>
24 <data1000>
25 HTTP/1.1 200 A OK
26 Server: Microsoft-IIS/6.0
27 Content-Type: text/html; charset=iso-8859-1
28 Content-Length: 3
29
30 ok
31 </data1000>
32 <datacheck>
33 HTTP/1.1 407 no, tell me who you are first
34 Date: Thu, 09 Nov 2010 14:49:00 GMT
35 Server: test-server/fake
36 Proxy-Authenticate: Digest realm="many secrets", nonce="911"
37 Content-Length: 0
38
39 HTTP/1.1 200 A OK
40 Server: Microsoft-IIS/6.0
41 Content-Type: text/html; charset=iso-8859-1
42 Content-Length: 3
43
44 ok
45 </datacheck>
46
47 </reply>
48
49 # Client-side
50 <client>
51 <server>
52 http
53 </server>
54 <features>
55 !SSPI
56 crypto
57 proxy
58 </features>
59 <name>
60 HTTP POST multipart with Expect: header using proxy anyauth (Digest)
61 </name>
62 <command>
63 -x http://%HOSTIP:%HTTPPORT http://remotehost:54321/we/want/259 -F name=daniel -F tool=curl -F file=@log/test259.txt -U uuuser:pppassword --proxy-anyauth -H "Expect: 100-continue"
64 </command>
65 # We create this file before the command is invoked!
66 <file name="log/test259.txt">
67 foo-
68 This is a moo-
69 bar
70 </file>
71 </client>
72
73 # Verify data after the test has been "shot"
74 <verify>
75 <strip>
76 ^(User-Agent:|Content-Type: multipart/form-data;|------).*
77 </strip>
78 <protocol>
79 POST http://remotehost:54321/we/want/259 HTTP/1.1
80 Host: remotehost:54321
81 User-Agent: curl/7.10.4 (i686-pc-linux-gnu) libcurl/7.10.4 OpenSSL/0.9.7a ipv6 zlib/1.1.3
82 Accept: */*
83 Proxy-Connection: Keep-Alive
84 Expect: 100-continue
85 Content-Length: 409
86 Content-Type: multipart/form-data; boundary=----------------------------7c633d5c27ce
87
88 ------------------------------7c633d5c27ce
89 Content-Disposition: form-data; name="name"
90
91 daniel
92 ------------------------------7c633d5c27ce
93 Content-Disposition: form-data; name="tool"
94
95 curl
96 ------------------------------7c633d5c27ce
97 Content-Disposition: form-data; name="file"; filename="test259.txt"
98 Content-Type: text/plain
99
100 foo-
101 This is a moo-
102 bar
103
104 ------------------------------7c633d5c27ce--
105 POST http://remotehost:54321/we/want/259 HTTP/1.1
106 Host: remotehost:54321
107 User-Agent: curl/7.10.4 (i686-pc-linux-gnu) libcurl/7.10.4 OpenSSL/0.9.7a ipv6 zlib/1.1.3
108 Proxy-Authorization: Digest username="uuuser", realm="many secrets", nonce="911", uri="/we/want/259", response="b479994d13e60f3aa192a67c5892ddc5"
109 Accept: */*
110 Proxy-Connection: Keep-Alive
111 Expect: 100-continue
112 Content-Length: 409
113 Content-Type: multipart/form-data; boundary=----------------------------7c633d5c27ce
114
115 ------------------------------7c633d5c27ce
116 Content-Disposition: form-data; name="name"
117
118 daniel
119 ------------------------------7c633d5c27ce
120 Content-Disposition: form-data; name="tool"
121
122 curl
123 ------------------------------7c633d5c27ce
124 Content-Disposition: form-data; name="file"; filename="test259.txt"
125 Content-Type: text/plain
126
127 foo-
128 This is a moo-
129 bar
130
131 ------------------------------7c633d5c27ce--
132 </protocol>
133 </verify>
134 </testcase>