Forum Discussion
hooleylist
Sep 23, 2008Cirrostratus
I'd suggest creating a 0.0.0.0:80 VIP (wildcard vip on a specific port) with an HTTP profile. You should then be able to use a rule like this to check for the cookie:
when HTTP_REQUEST {
Check if the cookie exists
if {[HTTP::cookie exists "my_cookie"]}{
Use the proxy pool
pool proxy_pool
} else {
Redirect the client
HTTP::redirect "http://redirected.example.com"
}
}
You might want to try adding some kind of validation of the cookie value as the above example could be bypassed by a client manually inserting a cookie with the name.
Aaron