xref: /curl/tests/data/test1331 (revision 3fd80c7b)
1<testcase>
2# Test case inspired by this question on stackoverflow:
3#
4# https://stackoverflow.com/questions/10017165/use-libcurl-with-bluecoat-cookie-proxy
5#
6<info>
7<keywords>
8HTTP
9HTTP GET
10HTTP proxy
11cookies
12</keywords>
13</info>
14
15# Server-side
16<reply>
17<data>
18HTTP/1.1 407 Me not know you swsbounce
19Date: Tue, 25 Sep 2001 19:37:44 GMT
20Content-Type: text/html
21Set-Cookie: proxycookie=weirdo; Path=/
22Cache-control: private
23Content-Length: 62
24Proxy-Authenticate: Basic realm="moo on you"
25
26This server reply is for testing a simple cookie test case...
27</data>
28
29<data1>
30HTTP/1.1 200 Fine!
31Content-Type: text/html
32Content-Length: 6
33
34hello
35</data1>
36
37<datacheck>
38HTTP/1.1 407 Me not know you swsbounce
39Date: Tue, 25 Sep 2001 19:37:44 GMT
40Content-Type: text/html
41Set-Cookie: proxycookie=weirdo; Path=/
42Cache-control: private
43Content-Length: 62
44Proxy-Authenticate: Basic realm="moo on you"
45
46HTTP/1.1 200 Fine!
47Content-Type: text/html
48Content-Length: 6
49
50hello
51</datacheck>
52
53
54</reply>
55
56# Client-side
57<client>
58<server>
59http
60</server>
61<name>
62HTTP --proxy-anyauth and 407 with cookies
63</name>
64<command>
65-U myname:mypassword -x %HOSTIP:%HTTPPORT http://z.x.com/%TESTNUMBER --proxy-anyauth -c %LOGDIR/dump%TESTNUMBER
66</command>
67<features>
68cookies
69proxy
70</features>
71</client>
72
73# Verify data after the test has been "shot"
74<verify>
75<protocol>
76GET http://z.x.com/%TESTNUMBER HTTP/1.1
77Host: z.x.com
78User-Agent: curl/%VERSION
79Accept: */*
80Proxy-Connection: Keep-Alive
81
82GET http://z.x.com/%TESTNUMBER HTTP/1.1
83Host: z.x.com
84Proxy-Authorization: Basic bXluYW1lOm15cGFzc3dvcmQ=
85User-Agent: curl/%VERSION
86Accept: */*
87Proxy-Connection: Keep-Alive
88Cookie: proxycookie=weirdo
89
90</protocol>
91</verify>
92</testcase>
93