Revert "Update to 7.44.0"
[platform/upstream/curl.git] / tests / data / test155
index 6b0ff5a..4e0870a 100644 (file)
@@ -1,3 +1,12 @@
+<testcase>
+<info>
+<keywords>
+HTTP
+HTTP PUT
+HTTP NTLM auth
+</keywords>
+</info>
+
 # Server-side
 <reply>
 <servercmd>
@@ -33,6 +42,7 @@ This is not the real page either!
 HTTP/1.1 200 Type-3 Recevied and all Things are fine swsclose\r
 Server: Microsoft-IIS/5.0\r
 Content-Type: text/html; charset=iso-8859-1\r
+Content-Length: 32\r
 \r
 Finally, this is the real page!
 </data1002>
@@ -55,6 +65,7 @@ WWW-Authenticate: NTLM TlRMTVNTUAACAAAAAgACADAAAAAGgoEAc51AYVDgyNcAAAAAAAAAAG4Ab
 HTTP/1.1 200 Type-3 Recevied and all Things are fine swsclose\r
 Server: Microsoft-IIS/5.0\r
 Content-Type: text/html; charset=iso-8859-1\r
+Content-Length: 32\r
 \r
 Finally, this is the real page!
 </datacheck>
@@ -65,6 +76,8 @@ Finally, this is the real page!
 <client>
 <features>
 NTLM
+!SSPI
+debug
 </features>
 <server>
 http
@@ -72,9 +85,18 @@ http
  <name>
 HTTP PUT with --anyauth authorization (picking NTLM)
  </name>
+ <setenv>
+# we force our own host name, in order to make the test machine independent
+CURL_GETHOSTNAME=curlhost
+# we try to use the LD_PRELOAD hack, if not a debug build
+LD_PRELOAD=%PWD/libtest/.libs/libhostname.so
+ </setenv>
  <command>
 http://%HOSTIP:%HTTPPORT/155 -T log/put155 -u testuser:testpass --anyauth
 </command>
+<precheck>
+chkhostname curlhost
+</precheck>
 <file name="log/put155">
 This is data we upload with PUT
 a second line
@@ -88,29 +110,23 @@ four is the number of lines
 <strip>
 ^User-Agent:.*
 </strip>
-# We strip off a large chunk of the type-2 NTLM message since it depends on
-# the local host name and thus differs on different machines!
-<strippart>
-s/^(Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAA).*/$1/
-</strippart)
 <protocol>
 PUT /155 HTTP/1.1\r
-Host: 127.0.0.1:%HTTPPORT\r
+Host: %HOSTIP:%HTTPPORT\r
 Accept: */*\r
 Content-Length: 85\r
 Expect: 100-continue\r
 \r
 PUT /155 HTTP/1.1\r
-Authorization: NTLM TlRMTVNTUAABAAAABoIAAAAAAAAAAAAAAAAAAAAAAAA=\r
-Host: 127.0.0.1:%HTTPPORT\r
+Authorization: NTLM TlRMTVNTUAABAAAABoIIAAAAAAAAAAAAAAAAAAAAAAA=\r
+Host: %HOSTIP:%HTTPPORT\r
 Accept: */*\r
 Content-Length: 0\r
-Expect: 100-continue\r
 \r
 PUT /155 HTTP/1.1\r
-Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAAAYABgAWAAAAAAAAABwAAAACAAIAHAAAAA
+Authorization: NTLM TlRMTVNTUAADAAAAGAAYAEAAAACeAJ4AWAAAAAAAAAD2AAAACAAIAPYAAAAIAAgA/gAAAAAAAAAAAAAABoKBAL9LNW5+nkyHZRmyFaL/LJ4xMjM0MjIzNGUCyhgQ9hw6eWAT13EbDa0BAQAAAAAAAACAPtXesZ0BMTIzNDIyMzQAAAAAAgAEAEMAQwABABIARQBMAEkAUwBBAEIARQBUAEgABAAYAGMAYwAuAGkAYwBlAGQAZQB2AC4AbgB1AAMALABlAGwAaQBzAGEAYgBlAHQAaAAuAGMAYwAuAGkAYwBlAGQAZQB2AC4AbgB1AAAAAAAAAAAAdGVzdHVzZXJjdXJsaG9zdA==\r
 User-Agent: curl/7.10.5 (i686-pc-linux-gnu) libcurl/7.10.5 OpenSSL/0.9.7a ipv6 zlib/1.1.3\r
-Host: 127.0.0.1:%HTTPPORT\r
+Host: %HOSTIP:%HTTPPORT\r
 Accept: */*\r
 Content-Length: 85\r
 Expect: 100-continue\r
@@ -121,3 +137,4 @@ line three
 four is the number of lines
 </protocol>
 </verify>
+</testcase>