File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / curl / tests / data / test89
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 NTLM auth
    7: followlocation
    8: </keywords>
    9: </info>
   10: # Server-side
   11: <reply>
   12: 
   13: <!-- no <data> in this test since we have NTLM from the start
   14: 
   15: This is supposed to be returned when the server gets a first
   16: Authorization: NTLM line passed-in from the client -->
   17: 
   18: <data1001>
   19: HTTP/1.1 401 Now gimme that second request of crap
   20: Server: Microsoft-IIS/5.0
   21: Content-Type: text/html; charset=iso-8859-1
   22: Content-Length: 34
   23: WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
   24: 
   25: This is not the real page either!
   26: </data1001>
   27: 
   28: # This is supposed to be returned when the server gets the second
   29: # Authorization: NTLM line passed-in from the client
   30: <data1002>
   31: HTTP/1.1 301 Things are fine in server land swsclose
   32: Server: Microsoft-IIS/5.0
   33: Connection: close
   34: Location: /you/890010
   35: 
   36: </data1002>
   37: 
   38: # This is the first reply after the redirection
   39: <data1011>
   40: HTTP/1.1 401 Now gimme that second round of crap
   41: Server: Microsoft-IIS/5.0
   42: Content-Type: text/html; charset=iso-8859-1
   43: Content-Length: 34
   44: WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
   45: 
   46: This is not the real page either!
   47: </data1011>
   48: 
   49: # This is supposed to be returned when the server gets the second
   50: # Authorization: NTLM line passed-in from the client
   51: <data1012>
   52: HTTP/1.1 200 Things are fine in server land swsclose
   53: Server: Microsoft-IIS/5.0
   54: Content-Type: text/html; charset=iso-8859-1
   55: Content-Length: 32
   56: 
   57: Finally, this is the real page!
   58: </data1012>
   59: 
   60: <datacheck>
   61: HTTP/1.1 401 Now gimme that second request of crap
   62: Server: Microsoft-IIS/5.0
   63: Content-Type: text/html; charset=iso-8859-1
   64: Content-Length: 34
   65: WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
   66: 
   67: HTTP/1.1 301 Things are fine in server land swsclose
   68: Server: Microsoft-IIS/5.0
   69: Connection: close
   70: Location: /you/890010
   71: 
   72: HTTP/1.1 401 Now gimme that second round of crap
   73: Server: Microsoft-IIS/5.0
   74: Content-Type: text/html; charset=iso-8859-1
   75: Content-Length: 34
   76: WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
   77: 
   78: HTTP/1.1 200 Things are fine in server land swsclose
   79: Server: Microsoft-IIS/5.0
   80: Content-Type: text/html; charset=iso-8859-1
   81: Content-Length: 32
   82: 
   83: Finally, this is the real page!
   84: </datacheck>
   85: 
   86: </reply>
   87: 
   88: # Client-side
   89: <client>
   90: <features>
   91: NTLM
   92: SSL
   93: !SSPI
   94: debug
   95: </features>
   96: <server>
   97: http
   98: </server>
   99:  <name>
  100: HTTP with NTLM and follow-location
  101:  </name>
  102:  <setenv>
  103: # we force our own host name, in order to make the test machine independent
  104: CURL_GETHOSTNAME=curlhost
  105: # we try to use the LD_PRELOAD hack, if not a debug build
  106: LD_PRELOAD=%PWD/libtest/.libs/libhostname.so
  107:  </setenv>
  108:  <command>
  109: http://%HOSTIP:%HTTPPORT/89 -u testuser:testpass --ntlm -L
  110: </command>
  111: <precheck>
  112: chkhostname curlhost
  113: </precheck>
  114: </client>
  115: 
  116: # Verify data after the test has been "shot"
  117: <verify>
  118: <strip>
  119: ^User-Agent:.*
  120: </strip>
  121: <protocol>
  122: GET /89 HTTP/1.1
  123: Host: %HOSTIP:%HTTPPORT
  124: Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
  125: User-Agent: curl/7.10.6-pre1 (i686-pc-linux-gnu) libcurl/7.10.6-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3
  126: Accept: */*
  127: 
  128: GET /89 HTTP/1.1
  129: Host: %HOSTIP:%HTTPPORT
  130: Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoIBADQzMjE1MzIxAAAAAAAAAAAAAAAAAAAAADj3hs3u3j0kgJqCrLM+74BmaoNHDfIJjHRlc3R1c2VyY3VybGhvc3Q=
  131: User-Agent: curl/7.10.6-pre1 (i686-pc-linux-gnu) libcurl/7.10.6-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3
  132: Accept: */*
  133: 
  134: GET /you/890010 HTTP/1.1
  135: Host: %HOSTIP:%HTTPPORT
  136: Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
  137: User-Agent: curl/7.10.8-pre1 (i686-pc-linux-gnu) libcurl/7.10.8-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3 GSS
  138: Accept: */*
  139: 
  140: GET /you/890010 HTTP/1.1
  141: Host: %HOSTIP:%HTTPPORT
  142: Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoIBADYzMjE3MzIxAAAAAAAAAAAAAAAAAAAAAEcJ4YHOeb5ga2TCPwDhkyUIuHjBUHcLaHRlc3R1c2VyY3VybGhvc3Q=
  143: User-Agent: curl/7.10.8-pre1 (i686-pc-linux-gnu) libcurl/7.10.8-pre1 OpenSSL/0.9.7a ipv6 zlib/1.1.3 GSS
  144: Accept: */*
  145: 
  146: </protocol>
  147: </verify>
  148: </testcase>

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