test62 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  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: Thu, 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/62 http://%HOSTIP:%HTTPPORT/we/want?hoge=fuga -b log/jar62.txt -H "Host: www.host.foo.com"
  30. </command>
  31. <file name="log/jar62.txt">
  32. # Netscape HTTP Cookie File
  33. # http://curl.haxx.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 2054030187 test yes
  36. .host.foo.com TRUE /we/want/ FALSE 2054030187 test2 yes
  37. .fake.host.foo.com TRUE /we/want/ FALSE 2054030187 test4 yes
  38. .foo.com TRUE /moo TRUE 0 test3 maybe
  39. </file>
  40. </client>
  41. # Verify data after the test has been "shot"
  42. <verify>
  43. <strip>
  44. ^User-Agent:.*
  45. </strip>
  46. <protocol>
  47. GET /we/want/62 HTTP/1.1
  48. Accept: */*
  49. Cookie: test2=yes; test=yes
  50. Host: www.host.foo.com
  51. GET /we/want?hoge=fuga HTTP/1.1
  52. Accept: */*
  53. Cookie: test2=yes; test=yes
  54. Host: www.host.foo.com
  55. </protocol>
  56. </verify>
  57. </testcase>