Return to test1008 CVS log | Up to [ELWIX - Embedded LightWeight unIX -] / embedaddon / curl / tests / data |
1.1 ! misho 1: <testcase> ! 2: <info> ! 3: <keywords> ! 4: HTTP ! 5: HTTP GET ! 6: HTTP CONNECT ! 7: HTTP proxy ! 8: HTTP proxy NTLM auth ! 9: chunked Transfer-Encoding ! 10: </keywords> ! 11: </info> ! 12: ! 13: # Server-side ! 14: <reply> ! 15: <servercmd> ! 16: connection-monitor ! 17: </servercmd> ! 18: ! 19: # this is returned first since we get no proxy-auth ! 20: <connect1001> ! 21: HTTP/1.1 407 Authorization Required to proxy me my dear ! 22: Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA== ! 23: Transfer-Encoding: chunked ! 24: ! 25: 20 ! 26: And you should ignore this data. ! 27: FA0 ! 28: XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX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XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX ! 29: 0 ! 30: ! 31: </connect1001> ! 32: ! 33: # This is supposed to be returned when the server gets the second ! 34: # Authorization: NTLM line passed-in from the client ! 35: <connect1002> ! 36: HTTP/1.1 200 Things are fine in proxy land ! 37: Server: Microsoft-IIS/5.0 ! 38: Content-Type: text/html; charset=iso-8859-1 ! 39: ! 40: </connect1002> ! 41: ! 42: # this is returned when we get a GET! ! 43: <data2> ! 44: HTTP/1.1 200 OK ! 45: Date: Thu, 09 Nov 2010 14:49:00 GMT ! 46: Content-Length: 7 ! 47: Connection: close ! 48: Content-Type: text/html ! 49: Funny-head: yesyes ! 50: ! 51: daniel ! 52: </data2> ! 53: ! 54: # then this is returned when we get proxy-auth ! 55: <data1000> ! 56: HTTP/1.1 200 OK swsbounce ! 57: Server: no ! 58: ! 59: Nice proxy auth sir! ! 60: </data1000> ! 61: ! 62: <datacheck> ! 63: HTTP/1.1 407 Authorization Required to proxy me my dear ! 64: Proxy-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA== ! 65: Transfer-Encoding: chunked ! 66: ! 67: HTTP/1.1 200 Things are fine in proxy land ! 68: Server: Microsoft-IIS/5.0 ! 69: Content-Type: text/html; charset=iso-8859-1 ! 70: ! 71: HTTP/1.1 200 OK ! 72: Date: Thu, 09 Nov 2010 14:49:00 GMT ! 73: Content-Length: 7 ! 74: Connection: close ! 75: Content-Type: text/html ! 76: Funny-head: yesyes ! 77: ! 78: daniel ! 79: </datacheck> ! 80: </reply> ! 81: ! 82: # Client-side ! 83: <client> ! 84: <server> ! 85: http ! 86: </server> ! 87: <features> ! 88: NTLM ! 89: SSL ! 90: !SSPI ! 91: debug ! 92: proxy ! 93: </features> ! 94: <name> ! 95: HTTP proxy CONNECT auth NTLM with chunked-encoded 407 response ! 96: </name> ! 97: <setenv> ! 98: # we force our own host name, in order to make the test machine independent ! 99: CURL_GETHOSTNAME=curlhost ! 100: # we try to use the LD_PRELOAD hack, if not a debug build ! 101: LD_PRELOAD=%PWD/libtest/.libs/libhostname.so ! 102: </setenv> ! 103: <command> ! 104: http://test.remote.example.com.1008:%HTTPPORT/path/10080002 --proxy http://%HOSTIP:%HTTPPORT --proxy-user testuser:testpass --proxy-ntlm --proxytunnel ! 105: </command> ! 106: <precheck> ! 107: chkhostname curlhost ! 108: </precheck> ! 109: </client> ! 110: ! 111: # Verify data after the test has been "shot" ! 112: <verify> ! 113: <strip> ! 114: ^User-Agent: curl/.* ! 115: </strip> ! 116: <protocol> ! 117: CONNECT test.remote.example.com.1008:%HTTPPORT HTTP/1.1 ! 118: Host: test.remote.example.com.1008:%HTTPPORT ! 119: Proxy-Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA= ! 120: Proxy-Connection: Keep-Alive ! 121: ! 122: CONNECT test.remote.example.com.1008:%HTTPPORT HTTP/1.1 ! 123: Host: test.remote.example.com.1008:%HTTPPORT ! 124: Proxy-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoIBADQzMjE1MzIxAAAAAAAAAAAAAAAAAAAAADj3hs3u3j0kgJqCrLM+74BmaoNHDfIJjHRlc3R1c2VyY3VybGhvc3Q= ! 125: Proxy-Connection: Keep-Alive ! 126: ! 127: GET /path/10080002 HTTP/1.1 ! 128: User-Agent: curl/7.12.3-CVS (i686-pc-linux-gnu) libcurl/7.12.3-CVS OpenSSL/0.9.6b zlib/1.1.4 ! 129: Host: test.remote.example.com.1008:%HTTPPORT ! 130: Accept: */* ! 131: ! 132: [DISCONNECT] ! 133: </protocol> ! 134: </verify> ! 135: </testcase>