test62 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
  1. <testcase>
  2. <info>
  3. <keywords>
  4. HTTP
  5. HTTP GET
  6. HTTP replaced headers
  7. cookies
  8. httponly
  9. </keywords>
  10. </info>
  11. # Server-side
  12. <reply>
  13. <data>
  14. HTTP/1.0 200 OK swsclose
  15. Date: Tue, 09 Nov 2010 14:49:00 GMT
  16. Content-Type: text/html
  17. boo
  18. </data>
  19. </reply>
  20. # Client-side
  21. <client>
  22. <server>
  23. http
  24. </server>
  25. <name>
  26. HTTP, send cookies when using custom Host:
  27. </name>
  28. <command>
  29. http://%HOSTIP:%HTTPPORT/we/want/%TESTNUMBER http://%HOSTIP:%HTTPPORT/we/want/%TESTNUMBER?hoge=fuga -b %LOGDIR/jar%TESTNUMBER.txt -H "Host: www.host.foo.com"
  30. </command>
  31. <file name="%LOGDIR/jar%TESTNUMBER.txt">
  32. # Netscape HTTP Cookie File
  33. # https://curl.se/docs/http-cookies.html
  34. # This file was generated by libcurl! Edit at your own risk.
  35. #HttpOnly_.foo.com TRUE /we/want/ FALSE 22147483647 test yes
  36. .host.foo.com TRUE /we/want/ FALSE 22147483647 test2 yes
  37. .fake.host.foo.com TRUE /we/want/ FALSE 22147483647 test4 yes
  38. .foo.com TRUE /moo TRUE 0 test3 maybe
  39. </file>
  40. <features>
  41. cookies
  42. </features>
  43. </client>
  44. # Verify data after the test has been "shot"
  45. <verify>
  46. <protocol>
  47. GET /we/want/%TESTNUMBER HTTP/1.1
  48. Host: www.host.foo.com
  49. User-Agent: curl/%VERSION
  50. Accept: */*
  51. Cookie: test2=yes; test=yes
  52. GET /we/want/%TESTNUMBER?hoge=fuga HTTP/1.1
  53. Host: www.host.foo.com
  54. User-Agent: curl/%VERSION
  55. Accept: */*
  56. Cookie: test2=yes; test=yes
  57. </protocol>
  58. </verify>
  59. </testcase>