test69 3.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121
  1. <testcase>
  2. <info>
  3. <keywords>
  4. HTTP
  5. HTTP GET
  6. HTTP NTLM auth
  7. </keywords>
  8. </info>
  9. # Server-side
  10. <reply>
  11. <data>
  12. HTTP/1.1 401 Authorization Required swsclose
  13. Server: Apache/1.3.27 (Darwin) PHP/4.1.2
  14. WWW-Authenticate: Basic
  15. WWW-Authenticate: Wild-and-crazy
  16. WWW-Authenticate: NTLM
  17. Content-Type: text/html; charset=iso-8859-1
  18. Content-Length: 26
  19. This is not the real page
  20. </data>
  21. # This is supposed to be returned when the server gets a first
  22. # Authorization: NTLM line passed-in from the client
  23. <data1001>
  24. HTTP/1.1 401 Now gimme that second request of crap
  25. Server: Microsoft-IIS/5.0
  26. Content-Length: 34
  27. Content-Type: text/html; charset=iso-8859-1
  28. WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
  29. This is not the real page either!
  30. </data1001>
  31. # This is supposed to be returned when the server gets the second
  32. # Authorization: NTLM line passed-in from the client
  33. <data1002>
  34. HTTP/1.1 200 Things are fine in server land swsclose
  35. Server: Microsoft-IIS/5.0
  36. Content-Type: text/html; charset=iso-8859-1
  37. Content-Length: 32
  38. Finally, this is the real page!
  39. </data1002>
  40. <datacheck>
  41. HTTP/1.1 401 Authorization Required swsclose
  42. Server: Apache/1.3.27 (Darwin) PHP/4.1.2
  43. WWW-Authenticate: Basic
  44. WWW-Authenticate: Wild-and-crazy
  45. WWW-Authenticate: NTLM
  46. Content-Type: text/html; charset=iso-8859-1
  47. Content-Length: 26
  48. HTTP/1.1 401 Now gimme that second request of crap
  49. Server: Microsoft-IIS/5.0
  50. Content-Length: 34
  51. Content-Type: text/html; charset=iso-8859-1
  52. WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAACGggEAc51AYVDgyNcAAAAAAAAAAG4AbgAyAAAAQ0MCAAQAQwBDAAEAEgBFAEwASQBTAEEAQgBFAFQASAAEABgAYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAwAsAGUAbABpAHMAYQBiAGUAdABoAC4AYwBjAC4AaQBjAGUAZABlAHYALgBuAHUAAAAAAA==
  53. HTTP/1.1 200 Things are fine in server land swsclose
  54. Server: Microsoft-IIS/5.0
  55. Content-Type: text/html; charset=iso-8859-1
  56. Content-Length: 32
  57. Finally, this is the real page!
  58. </datacheck>
  59. </reply>
  60. # Client-side
  61. <client>
  62. <features>
  63. NTLM
  64. SSL
  65. !SSPI
  66. debug
  67. </features>
  68. <server>
  69. http
  70. </server>
  71. <name>
  72. HTTP with NTLM, Basic or Wild-and-crazy authorization
  73. </name>
  74. <setenv>
  75. # we force our own host name, in order to make the test machine independent
  76. CURL_GETHOSTNAME=curlhost
  77. # we try to use the LD_PRELOAD hack, if not a debug build
  78. LD_PRELOAD=%PWD/libtest/.libs/libhostname.so
  79. </setenv>
  80. <command>
  81. http://%HOSTIP:%HTTPPORT/%TESTNUMBER -u testuser:testpass --anyauth
  82. </command>
  83. <precheck>
  84. chkhostname curlhost
  85. </precheck>
  86. </client>
  87. # Verify data after the test has been "shot"
  88. <verify>
  89. <protocol>
  90. GET /%TESTNUMBER HTTP/1.1
  91. Host: %HOSTIP:%HTTPPORT
  92. User-Agent: curl/%VERSION
  93. Accept: */*
  94. GET /%TESTNUMBER HTTP/1.1
  95. Host: %HOSTIP:%HTTPPORT
  96. Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=
  97. User-Agent: curl/%VERSION
  98. Accept: */*
  99. GET /%TESTNUMBER HTTP/1.1
  100. Host: %HOSTIP:%HTTPPORT
  101. Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAAIAAgAeAAAAAAAAAAAAAAAhoIBAFpkQwKRCZFMhjj0tw47wEjKHRHlvzfxQamFcheMuv8v+xeqphEO5V41xRd7R9deOXRlc3R1c2VyY3VybGhvc3Q=
  102. User-Agent: curl/%VERSION
  103. Accept: */*
  104. </protocol>
  105. </verify>
  106. </testcase>