1<testcase>
2<info>
3<keywords>
4HTTP
5HTTP GET
6HTTP proxy
7HTTP 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>
17HTTP/1.1 407 Now gimme that second request of crap
18Server: Microsoft-IIS/5.0
19Content-Type: text/html; charset=iso-8859-1
20Content-Length: 34
21Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAAAGgoEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
22
23This 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>
29HTTP/1.1 200 Things are fine in server land swsclose
30Server: Microsoft-IIS/5.0
31Content-Type: text/html; charset=iso-8859-1
32Content-Length: 32
33
34Finally, this is the real page!
35</data1002>
36
37<datacheck>
38HTTP/1.1 407 Now gimme that second request of crap
39Server: Microsoft-IIS/5.0
40Content-Type: text/html; charset=iso-8859-1
41Content-Length: 34
42Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAAAGgoEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
43
44HTTP/1.1 200 Things are fine in server land swsclose
45Server: Microsoft-IIS/5.0
46Content-Type: text/html; charset=iso-8859-1
47Content-Length: 32
48
49Finally, this is the real page!
50</datacheck>
51
52</reply>
53
54# Client-side
55<client>
56<features>
57NTLM
58!SSPI
59</features>
60<server>
61http
62</server>
63 <name>
64HTTP with proxy using NTLM authorization
65 </name>
66 <setenv>
67# we force our own host name, in order to make the test machine independent
68CURL_GETHOSTNAME=curlhost
69# we try to use the LD_PRELOAD hack, if not a debug build
70LD_PRELOAD=%PWD/libtest/.libs/libhostname.so
71 </setenv>
72 <command>
73http://%HOSTIP:%HTTPPORT/81 --proxy-user testuser:testpass -x http://%HOSTIP:%HTTPPORT --proxy-ntlm
74</command>
75<precheck>
76chkhostname curlhost
77</precheck>
78</client>
79
80# Verify data after the test has been "shot"
81<verify>
82<strip>
83^User-Agent:.*
84</strip>
85<protocol>
86GET http://%HOSTIP:%HTTPPORT/81 HTTP/1.1
87Proxy-Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
88User-Agent: curl/7.10.6-pre1 (i686-pc-linux-gnu) libcurl/7.10.6-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3
89Host: %HOSTIP:%HTTPPORT
90Accept: */*
91Proxy-Connection: Keep-Alive
92
93GET http://%HOSTIP:%HTTPPORT/81 HTTP/1.1
94Proxy-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAACeAJ4AWAAAAAAAAAD2AAAACAAIAPYAAAAIAAgA/gAAAAAAAAAAAAAABoKBAFuu0VIvKeMdPwjDPk7eAnwxMjM0NTY3OC1uDhL9DbZXt27JqdXMDkABAQAAAAAAAACAPtXesZ0BMTIzNDU2NzgAAAAAAgAEAEMAQwABABIARQBMAEkAUwBBAEIARQBUAEgABAAYAGMAYwAuAGkAYwBlAGQAZQB2AC4AbgB1AAMALABlAGwAaQBzAGEAYgBlAHQAaAAuAGMAYwAuAGkAYwBlAGQAZQB2AC4AbgB1AAAAAAAAAAAAdGVzdHVzZXJjdXJsaG9zdA==
95User-Agent: curl/7.10.6-pre1 (i686-pc-linux-gnu) libcurl/7.10.6-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3
96Host: %HOSTIP:%HTTPPORT
97Accept: */*
98Proxy-Connection: Keep-Alive
99
100</protocol>
101</verify>
102</testcase>
103