Forum Discussion
Insert cookie after remote
Now,I found that after using insert cookie will take cookies in F5 to the server.So,I need to remote the cookie when F5 switch to serves,but use persistent cookie.
5 Replies
- Kevin_Stewart
Employee
Can you elaborate with examples? - mars_crow_10795
Nimbostratus
sniffer found: 1、client-F5 no cookie 2、F5-server no cookie 3、server-F5 no cookie 4、F5-client cookie (persistent) 5、client-F5 take cookie 6、F5-server take cookie(so ,I need to remote the cookie,and use persistent cookie) 7、server-F5 no cookie 8、F5-client cookie
- Kevin_Stewart
Employee
Apologies, but still not getting the sense of your requirement. When you say "remote", do you mean "remove"? If so, which cookie, and on which side?
- Kevin_Stewart
Employee
Okay, I think I understand. So you're setting a cookie on the client side for persistence, but then you don't want that cookie to show up on the back end server. If that's correct, then something like this would probably do the trick:
when HTTP_REQUEST { HTTP::cookie remove "BIGipServerlocal-pool" }where "BIGipServerlocal-pool" is the specific name of the persistence cookie that you want to remove from the inbound stream.
- Kevin_Stewart
Employee
Try this:
when HTTP_REQUEST { if { [HTTP::header Cookie] contains "BIGipServer" } { HTTP::cookie remove [findstr [HTTP::header Cookie] "BIGipServer" 0 "="] } }This assumes of course that you're using the default cookie persistence profile.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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