File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / curl / tests / data / test209
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Wed Jun 3 10:01:16 2020 UTC (5 years ago) by misho
Branches: curl, MAIN
CVS tags: v7_70_0p4, HEAD
curl

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

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>