1<testcase> 2<info> 3<keywords> 4HTTP 5HTTP GET 6HTTP proxy 7HTTP proxy NTLM auth 8HTTP Digest auth 9</keywords> 10</info> 11 12# Server-side 13<reply> 14 15# this is returned first since we get no proxy-auth 16<data> 17HTTP/1.1 407 Authorization Required to proxy me my dear swsclose 18Proxy-Authenticate: NTLM 19 20And you should ignore this data. 21</data> 22 23# then this is returned since we get no server-auth 24<data1000> 25HTTP/1.1 200 Authorizated fine 26Content-Length: 27 27 28Welcome to the end station 29</data1000> 30 31<data1001> 32HTTP/1.1 407 NTLM type-1 received sending back type-2 33Server: Microsoft-IIS/5.0 34Content-Length: 34 35Content-Type: text/html; charset=iso-8859-1 36Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA== 37 38This is not the real page either! 39</data1001> 40 41# This is supposed to be returned when the server gets the second 42# Authorization: NTLM line passed-in from the client 43<data1002> 44HTTP/1.1 401 You now need to authenticate with the host 45Server: Microsoft-IIS/5.0 46WWW-Authenticate: Digest realm="r e a l m", nonce="abcdef" 47Content-Length: 46 48Content-Type: text/html; charset=iso-8859-1 49 50We have not authenticated with the server yet 51</data1002> 52 53<datacheck> 54HTTP/1.1 407 NTLM type-1 received sending back type-2 55Server: Microsoft-IIS/5.0 56Content-Length: 34 57Content-Type: text/html; charset=iso-8859-1 58Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA== 59 60HTTP/1.1 401 You now need to authenticate with the host 61Server: Microsoft-IIS/5.0 62WWW-Authenticate: Digest realm="r e a l m", nonce="abcdef" 63Content-Length: 46 64Content-Type: text/html; charset=iso-8859-1 65 66HTTP/1.1 200 Authorizated fine 67Content-Length: 27 68 69Welcome to the end station 70</datacheck> 71</reply> 72 73# Client-side 74<client> 75<server> 76http 77</server> 78<features> 79NTLM 80SSL 81!SSPI 82debug 83proxy 84</features> 85 <name> 86HTTP with proxy-requiring-NTLM to site-requiring-Digest 87 </name> 88 <setenv> 89# we force our own host name, in order to make the test machine independent 90CURL_GETHOSTNAME=curlhost 91# we try to use the LD_PRELOAD hack, if not a debug build 92LD_PRELOAD=%PWD/libtest/.libs/libhostname.so 93 </setenv> 94 <command> 95http://data.from.server.requiring.digest.hohoho.com/169 --proxy http://%HOSTIP:%HTTPPORT --proxy-user testuser:testpass --proxy-ntlm --digest --user digest:alot 96</command> 97<precheck> 98chkhostname curlhost 99</precheck> 100</client> 101 102# Verify data after the test has been "shot" 103<verify> 104<protocol> 105GET http://data.from.server.requiring.digest.hohoho.com/169 HTTP/1.1 106Host: data.from.server.requiring.digest.hohoho.com 107Proxy-Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA= 108User-Agent: curl/%VERSION 109Accept: */* 110Proxy-Connection: Keep-Alive 111 112GET http://data.from.server.requiring.digest.hohoho.com/169 HTTP/1.1 113Host: data.from.server.requiring.digest.hohoho.com 114Proxy-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoIBADQzMjE1MzIxAAAAAAAAAAAAAAAAAAAAADj3hs3u3j0kgJqCrLM+74BmaoNHDfIJjHRlc3R1c2VyY3VybGhvc3Q= 115User-Agent: curl/%VERSION 116Accept: */* 117Proxy-Connection: Keep-Alive 118 119GET http://data.from.server.requiring.digest.hohoho.com/169 HTTP/1.1 120Host: data.from.server.requiring.digest.hohoho.com 121Authorization: Digest username="digest", realm="r e a l m", nonce="abcdef", uri="/169", response="95d48591985a03c4b49cb962aa7bd3e6" 122User-Agent: curl/%VERSION 123Accept: */* 124Proxy-Connection: Keep-Alive 125 126</protocol> 127</verify> 128</testcase> 129