- I removed the default use of "Pragma: no-cache" from libcurl when a proxy is
[platform/upstream/curl.git] / tests / data / test81
1 <testcase>
2 <info>
3 <keywords>
4 HTTP
5 HTTP GET
6 HTTP proxy
7 HTTP proxy NTLM auth
8 </keywords>
9 </info>
10
11 # Server-side
12 <reply>
13
14 # This is supposed to be returned when the server gets a first
15 # Authorization: NTLM line passed-in from the client
16 <data1001>
17 HTTP/1.1 407 Now gimme that second request of crap\r
18 Server: Microsoft-IIS/5.0\r
19 Content-Type: text/html; charset=iso-8859-1\r
20 Content-Length: 34\r
21 Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAAAGgoEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==\r
22 \r
23 This is not the real page either!
24 </data1001>
25
26 # This is supposed to be returned when the server gets the second
27 # Authorization: NTLM line passed-in from the client
28 <data1002>
29 HTTP/1.1 200 Things are fine in server land swsclose\r
30 Server: Microsoft-IIS/5.0\r
31 Content-Type: text/html; charset=iso-8859-1\r
32 Content-Length: 32\r
33 \r
34 Finally, this is the real page!
35 </data1002>
36
37 <datacheck>
38 HTTP/1.1 407 Now gimme that second request of crap\r
39 Server: Microsoft-IIS/5.0\r
40 Content-Type: text/html; charset=iso-8859-1\r
41 Content-Length: 34\r
42 Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAAAGgoEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==\r
43 \r
44 HTTP/1.1 200 Things are fine in server land swsclose\r
45 Server: Microsoft-IIS/5.0\r
46 Content-Type: text/html; charset=iso-8859-1\r
47 Content-Length: 32\r
48 \r
49 Finally, this is the real page!
50 </datacheck>
51
52 </reply>
53
54 # Client-side
55 <client>
56 <features>
57 NTLM
58 </features>
59 <server>
60 http
61 </server>
62  <name>
63 HTTP with proxy using NTLM authorization
64  </name>
65  <command>
66 http://%HOSTIP:%HTTPPORT/81 --proxy-user testuser:testpass -x http://%HOSTIP:%HTTPPORT --proxy-ntlm
67 </command>
68 </client>
69
70 # Verify data after the test has been "shot"
71 <verify>
72 <strip>
73 ^User-Agent:.*
74 </strip>
75 # We strip off a large chunk of the type-2 NTLM message since it depends on
76 # the local host name and thus differs on different machines!
77 <strippart>
78 s/(Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAA).*/$1/
79 </strippart>
80 <protocol>
81 GET http://%HOSTIP:%HTTPPORT/81 HTTP/1.1\r
82 Proxy-Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=\r
83 User-Agent: curl/7.10.6-pre1 (i686-pc-linux-gnu) libcurl/7.10.6-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3\r
84 Host: %HOSTIP:%HTTPPORT\r
85 Accept: */*\r
86 Proxy-Connection: Keep-Alive\r
87 \r
88 GET http://%HOSTIP:%HTTPPORT/81 HTTP/1.1\r
89 Proxy-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAA
90 User-Agent: curl/7.10.6-pre1 (i686-pc-linux-gnu) libcurl/7.10.6-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3\r
91 Host: %HOSTIP:%HTTPPORT\r
92 Accept: */*\r
93 Proxy-Connection: Keep-Alive\r
94 \r
95 </protocol>
96 </verify>
97 </testcase>