Forum Discussion
Robert_47833
Altostratus
Apr 16, 2013how to insert cookie for 2 domains
in HTTP::response event
HTTP::cookie insert name "test" value "00" path "/" domain "x.com"
besides this,I also want this cookie "test" be set in domain "xy.com"
is the second cookie tes...
hoolio
Cirrostratus
Apr 16, 2013Sorry for not completing the thought. The HTTP::respond command would be used on the x.com virtual server to send a redirect to xy.com and set a cookie for x.com. You'd want to use a specific URI in the redirect and probably set a session ID in a parameter value:
HTTP::respond 302 Location "http://site2.xy.com/set_session?sessionid=abcd" Set-Cookie "my_cookie_name=my_cookie_value; Domain=.x.com; Path=/"
On the xy.com virtual server you'd want to check for requests to /set_session and parse the sessionid parameter value. You could then set a cookie on the xy.com domain with the same value. You could then redirect the client back to the original x.com subdomain with the client then having two separate sessionid cookies set to the same value.
Does that make more sense?
Aaron
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects
