2007-01-23 03:25:56 +01:00
|
|
|
<testcase>
|
2005-04-22 23:59:08 +02:00
|
|
|
<info>
|
|
|
|
<keywords>
|
|
|
|
HTTP
|
|
|
|
HTTP GET
|
|
|
|
cookies
|
|
|
|
cookiejar
|
|
|
|
HTTP replaced headers
|
|
|
|
</keywords>
|
|
|
|
</info>
|
2003-04-30 21:49:51 +02:00
|
|
|
# Server-side
|
|
|
|
<reply>
|
|
|
|
<data>
|
|
|
|
HTTP/1.1 200 OK
|
|
|
|
Date: Thu, 09 Nov 2010 14:49:00 GMT
|
|
|
|
Server: test-server/fake
|
|
|
|
Content-Type: text/html
|
|
|
|
Funny-head: yesyes
|
2007-02-05 03:38:25 +01:00
|
|
|
Set-Cookie: test=yes; domain=foo.com; expires=Fri Feb 2 11:56:27 GMT 2035
|
2008-10-23 03:53:27 +02:00
|
|
|
SET-COOKIE: test2=yes; domain=host.foo.com; expires=Fri Feb 2 11:56:27 GMT 2035
|
2003-04-30 21:49:51 +02:00
|
|
|
Set-Cookie: test3=maybe; domain=foo.com; path=/moo; secure
|
|
|
|
Set-Cookie: test4=no; domain=nope.foo.com; path=/moo; secure
|
|
|
|
Set-Cookie: test5=name; domain=anything.com; path=/ ; secure
|
2003-07-20 01:57:08 +02:00
|
|
|
Content-Length: 4
|
2003-04-30 21:49:51 +02:00
|
|
|
|
|
|
|
boo
|
|
|
|
</data>
|
|
|
|
</reply>
|
|
|
|
|
|
|
|
# Client-side
|
|
|
|
<client>
|
2003-04-30 22:25:39 +02:00
|
|
|
<server>
|
|
|
|
http
|
|
|
|
</server>
|
2003-04-30 21:49:51 +02:00
|
|
|
<name>
|
|
|
|
HTTP with various cookies and custom Host:
|
|
|
|
</name>
|
2007-07-11 00:27:16 +02:00
|
|
|
# Explicitly set the time zone to a known good one, in case the user is
|
|
|
|
# using one of the 'right' zones that take into account leap seconds
|
|
|
|
# which causes the cookie expiry times to be different.
|
|
|
|
<setenv>
|
|
|
|
TZ=GMT
|
|
|
|
</setenv>
|
2003-04-30 21:49:51 +02:00
|
|
|
<command>
|
2004-09-08 10:08:38 +02:00
|
|
|
http://%HOSTIP:%HTTPPORT/we/want/61 -c log/jar61.txt -H "Host: www.host.foo.com"
|
2003-04-30 21:49:51 +02:00
|
|
|
</command>
|
2003-05-02 11:11:53 +02:00
|
|
|
</client>
|
2003-04-30 21:49:51 +02:00
|
|
|
|
|
|
|
# Verify data after the test has been "shot"
|
|
|
|
<verify>
|
|
|
|
<strip>
|
|
|
|
^User-Agent:.*
|
|
|
|
</strip>
|
|
|
|
<protocol>
|
|
|
|
GET /we/want/61 HTTP/1.1
|
2004-02-09 13:46:41 +01:00
|
|
|
Accept: */*
|
2003-04-30 21:49:51 +02:00
|
|
|
Host: www.host.foo.com
|
|
|
|
|
|
|
|
</protocol>
|
2007-01-23 03:25:56 +01:00
|
|
|
<file name="log/jar61.txt" mode="text">
|
2003-04-30 21:49:51 +02:00
|
|
|
# Netscape HTTP Cookie File
|
2008-08-28 13:35:54 +02:00
|
|
|
# http://curl.haxx.se/rfc/cookie_spec.html
|
2003-04-30 21:49:51 +02:00
|
|
|
# This file was generated by libcurl! Edit at your own risk.
|
|
|
|
|
2007-02-05 03:38:25 +01:00
|
|
|
.foo.com TRUE /we/want/ FALSE 2054030187 test yes
|
|
|
|
.host.foo.com TRUE /we/want/ FALSE 2054030187 test2 yes
|
2003-04-30 21:56:53 +02:00
|
|
|
.foo.com TRUE /moo TRUE 0 test3 maybe
|
2003-04-30 21:49:51 +02:00
|
|
|
</file>
|
|
|
|
</verify>
|
2007-01-23 03:25:56 +01:00
|
|
|
</testcase>
|