test1002 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124
  1. <testcase>
  2. <info>
  3. <keywords>
  4. HTTP
  5. HTTP PUT
  6. HTTP proxy
  7. HTTP Digest auth
  8. Resume
  9. Content-Range
  10. CUSTOMREQUEST
  11. </keywords>
  12. </info>
  13. <reply>
  14. <data>
  15. HTTP/1.1 100 Continue
  16. Server: Microsoft-IIS/5.0
  17. Date: Sun, 03 Apr 2005 14:57:45 GMT
  18. X-Powered-By: ASP.NET
  19. HTTP/1.1 401 authentication please swsbounce
  20. Server: Microsoft-IIS/6.0
  21. WWW-Authenticate: Digest realm="testrealm", nonce="1053604144"
  22. Content-Type: text/html; charset=iso-8859-1
  23. Content-Length: 0
  24. </data>
  25. <data1000>
  26. HTTP/1.1 200 A OK
  27. Server: Microsoft-IIS/6.0
  28. Content-Type: text/html; charset=iso-8859-1
  29. Content-Length: 3
  30. ok
  31. </data1000>
  32. <datacheck>
  33. HTTP/1.1 100 Continue
  34. Server: Microsoft-IIS/5.0
  35. Date: Sun, 03 Apr 2005 14:57:45 GMT
  36. X-Powered-By: ASP.NET
  37. HTTP/1.1 401 authentication please swsbounce
  38. Server: Microsoft-IIS/6.0
  39. WWW-Authenticate: Digest realm="testrealm", nonce="1053604144"
  40. Content-Type: text/html; charset=iso-8859-1
  41. Content-Length: 0
  42. HTTP/1.1 200 A OK
  43. Server: Microsoft-IIS/6.0
  44. Content-Type: text/html; charset=iso-8859-1
  45. Content-Length: 3
  46. ok
  47. </datacheck>
  48. </reply>
  49. # Client-side
  50. <client>
  51. #
  52. <server>
  53. http
  54. </server>
  55. <features>
  56. !SSPI
  57. crypto
  58. proxy
  59. </features>
  60. <name>
  61. HTTP PUT with Digest auth, resumed upload and modified method, twice
  62. </name>
  63. <command>
  64. http://%HOSTIP:%HTTPPORT/%TESTNUMBER.upload1 -T log/%TESTNUMBER http://%HOSTIP:%HTTPPORT/%TESTNUMBER.upload2 -T log/%TESTNUMBER -u auser:apasswd --digest -x http://%HOSTIP:%HTTPPORT -C 2 -X GET
  65. </command>
  66. <file name="log/%TESTNUMBER">
  67. test
  68. </file>
  69. </client>
  70. # Verify data after the test has been "shot"
  71. <verify>
  72. <protocol>
  73. GET http://%HOSTIP:%HTTPPORT/%TESTNUMBER.upload1 HTTP/1.1
  74. Host: %HOSTIP:%HTTPPORT
  75. Content-Range: bytes 2-4/5
  76. User-Agent: curl/%VERSION
  77. Accept: */*
  78. Proxy-Connection: Keep-Alive
  79. Content-Length: 0
  80. GET http://%HOSTIP:%HTTPPORT/%TESTNUMBER.upload1 HTTP/1.1
  81. Host: %HOSTIP:%HTTPPORT
  82. Authorization: Digest username="auser", realm="testrealm", nonce="1053604144", uri="/%TESTNUMBER.upload1", response="198aa9b6acb4b0c71d02a197a5e41f54"
  83. Content-Range: bytes 2-4/5
  84. User-Agent: curl/%VERSION
  85. Accept: */*
  86. Proxy-Connection: Keep-Alive
  87. Content-Length: 3
  88. Expect: 100-continue
  89. st
  90. GET http://%HOSTIP:%HTTPPORT/%TESTNUMBER.upload2 HTTP/1.1
  91. Host: %HOSTIP:%HTTPPORT
  92. Content-Range: bytes 2-4/5
  93. User-Agent: curl/%VERSION
  94. Accept: */*
  95. Proxy-Connection: Keep-Alive
  96. Content-Length: 0
  97. GET http://%HOSTIP:%HTTPPORT/%TESTNUMBER.upload2 HTTP/1.1
  98. Host: %HOSTIP:%HTTPPORT
  99. Authorization: Digest username="auser", realm="testrealm", nonce="1053604144", uri="/%TESTNUMBER.upload2", response="d711f0d2042786d930de635ba0d1a1d0"
  100. Content-Range: bytes 2-4/5
  101. User-Agent: curl/%VERSION
  102. Accept: */*
  103. Proxy-Connection: Keep-Alive
  104. Content-Length: 3
  105. Expect: 100-continue
  106. st
  107. </protocol>
  108. </verify>
  109. </testcase>