1 <testcase> 2 <info> 3 <keywords> 4 HTTP 5 HTTP GET 6 HTTP Basic auth 7 HTTP NTLM auth 8 pipelining 9 flaky 10 </keywords> 11 </info> 12 # Server-side 13 <reply> 14 15 <!-- Basic auth --> 16 <data100> 17 HTTP/1.1 401 Need Basic or NTLM auth 18 Server: Microsoft-IIS/5.0 19 Content-Type: text/html; charset=iso-8859-1 20 Content-Length: 29 21 WWW-Authenticate: NTLM 22 WWW-Authenticate: Basic realm="testrealm" 23 24 This is a bad password page! 25 </data100> 26 27 <!-- NTLM auth --> 28 <data200> 29 HTTP/1.1 401 Need Basic or NTLM auth (2) 30 Server: Microsoft-IIS/5.0 31 Content-Type: text/html; charset=iso-8859-1 32 Content-Length: 27 33 WWW-Authenticate: NTLM 34 WWW-Authenticate: Basic realm="testrealm" 35 36 This is not the real page! 37 </data200> 38 39 <data1201> 40 HTTP/1.1 401 NTLM intermediate (2) 41 Server: Microsoft-IIS/5.0 42 Content-Type: text/html; charset=iso-8859-1 43 Content-Length: 33 44 WWW-Authenticate: NTLM TlRMTVNTUAACAAAACAAIADAAAACGgAEAq6U1NAWaJCIAAAAAAAAAAAAAAAA4AAAATlRMTUF1dGg= 45 46 This is still not the real page! 47 </data1201> 48 49 <data1202> 50 HTTP/1.1 200 Things are fine in server land 51 Server: Microsoft-IIS/5.0 52 Content-Type: text/html; charset=iso-8859-1 53 Content-Length: 32 54 55 Finally, this is the real page! 56 </data1202> 57 58 <datacheck> 59 Data connection 0: 228 60 Data connection 1: 228 61 Data connection 2: 402 62 </datacheck> 63 64 </reply> 65 66 # Client-side 67 <client> 68 <features> 69 NTLM 70 !SSPI 71 </features> 72 <server> 73 http 74 </server> 75 <tool> 76 lib2033 77 </tool> 78 79 <name> 80 NTLM connection mapping, pipelining enabled 81 </name> 82 <setenv> 83 # we force our own host name, in order to make the test machine independent 84 CURL_GETHOSTNAME=curlhost 85 # we try to use the LD_PRELOAD hack, if not a debug build 86 LD_PRELOAD=%PWD/libtest/.libs/libhostname.so 87 </setenv> 88 <command> 89 http://%HOSTIP:%HTTPPORT/2032 90 </command> 91 <precheck> 92 chkhostname curlhost 93 </precheck> 94 </client> 95 96 # Verify data after the test has been "shot" 97 <verify> 98 <strip> 99 ^User-Agent:.* 100 </strip> 101 <protocol> 102 GET /20320100 HTTP/1.1 103 Host: 127.0.0.1:%HTTPPORT 104 Authorization: Basic dGVzdHVzZXI6dGVzdHBhc3M= 105 Accept: */* 106 107 GET /20320100 HTTP/1.1 108 Host: 127.0.0.1:%HTTPPORT 109 Authorization: Basic dGVzdHVzZXI6dGVzdHBhc3M= 110 Accept: */* 111 112 GET /20320200 HTTP/1.1 113 Host: 127.0.0.1:%HTTPPORT 114 Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA= 115 Accept: */* 116 117 GET /20320200 HTTP/1.1 118 Host: 127.0.0.1:%HTTPPORT 119 Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoABAI+/Fp9IERAQ74OsdNPbBpg7o8CVwLSO4DtFyIcZHUMKVktWIu92s2892OVpd2JzqnRlc3R1c2VyY3VybGhvc3Q= 120 Accept: */* 121 122 </protocol> 123 </verify> 124 </testcase> 125