Forum Discussion
mr_skater99_640
Nimbostratus
Mar 03, 2010Stripping Cookies
We have an off the shelf product that sets to many cookies and cookies on all domains configured in the product (these aren't needed). We're trying to tidy some of this up and we've got some of it wo...
nitass_89166
Noctilucent
Oct 26, 2012just wondering if quote really causes a problem. also, if quote is interpreted, how can we get cookie value of the cookie name which has quote e.g. foo.
[root@ve10:Active] config b virtual bar list
virtual bar {
snat automap
pool foo
destination 172.28.19.79:80
ip protocol 6
rules myrule
profiles {
http {}
tcp {}
}
}
[root@ve10:Active] config b pool foo list
pool foo {
members 200.200.200.101:80 {}
}
[root@ve10:Active] config b rule myrule list
rule myrule {
when HTTP_RESPONSE {
log local0. "\[HTTP::cookie names\]: [HTTP::cookie names]"
foreach a_cookie [HTTP::cookie names] {
log local0. "\$a_cookie: $a_cookie=[HTTP::cookie $a_cookie] (\$a_cookie=\[HTTP::cookie $a_cookie\])"
}
}
}
on client
[root@centos11 ~] curl -I http://172.28.19.79
HTTP/1.1 200 OK
Date: Fri, 26 Oct 2012 08:00:42 GMT
Server: Apache/2.2.3 (CentOS)
Last-Modified: Fri, 11 Nov 2011 14:48:14 GMT
ETag: "4183e4-3e-9c564780"
Accept-Ranges: bytes
Content-Length: 62
Set-Cookie: "foo"=123456; path=/
Set-Cookie: bar=abcdef; path=/
Connection: close
Content-Type: text/html; charset=UTF-8
log on bigip
[root@ve10:Active] config tail -f /var/log/ltm
Oct 26 15:43:18 local/tmm info tmm[7926]: Rule myrule : [HTTP::cookie names]: "foo" bar
Oct 26 15:43:18 local/tmm info tmm[7926]: Rule myrule : $a_cookie: foo= ($a_cookie=[HTTP::cookie foo])
Oct 26 15:43:18 local/tmm info tmm[7926]: Rule myrule : $a_cookie: bar=abcdef ($a_cookie=[HTTP::cookie bar])
Robert_47833
Altostratus
Dec 04, 2013by the way:single quote is another error:)
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