xref: /curl/tests/data/test185 (revision 3fd80c7b)
1<testcase>
2<info>
3<keywords>
4HTTP
5HTTP GET
6HTTP proxy
7followlocation
8</keywords>
9</info>
10
11# Server-side
12<reply>
13<data>
14HTTP/1.1 301 OK swsbounce
15Date: Tue, 09 Nov 2010 14:49:00 GMT
16Content-Length: 4
17Location: go/west/%TESTNUMBER
18
19moo
20</data>
21<data1>
22HTTP/1.1 200 OK
23Date: Tue, 09 Nov 2010 14:49:00 GMT
24Content-Length: 4
25
26moo
27</data1>
28<datacheck>
29HTTP/1.1 301 OK swsbounce
30Date: Tue, 09 Nov 2010 14:49:00 GMT
31Content-Length: 4
32Location: go/west/%TESTNUMBER
33
34HTTP/1.1 200 OK
35Date: Tue, 09 Nov 2010 14:49:00 GMT
36Content-Length: 4
37
38moo
39</datacheck>
40</reply>
41
42# Client-side
43<client>
44<server>
45http
46</server>
47<name>
48HTTP replace Host: when following Location: on the same host
49</name>
50<command>
51http://deathstar.another.galaxy/%TESTNUMBER -L -H "Host: another.visitor.stay.a.while.stay.foreeeeeever" --proxy http://%HOSTIP:%HTTPPORT
52</command>
53<features>
54proxy
55</features>
56</client>
57
58# Verify data after the test has been "shot"
59<verify>
60<protocol>
61GET http://deathstar.another.galaxy/%TESTNUMBER HTTP/1.1
62Host: another.visitor.stay.a.while.stay.foreeeeeever
63User-Agent: curl/%VERSION
64Accept: */*
65Proxy-Connection: Keep-Alive
66
67GET http://deathstar.another.galaxy/go/west/%TESTNUMBER HTTP/1.1
68Host: another.visitor.stay.a.while.stay.foreeeeeever
69User-Agent: curl/%VERSION
70Accept: */*
71Proxy-Connection: Keep-Alive
72
73</protocol>
74
75</verify>
76</testcase>
77