Forum Discussion
Ted_Smith_11168
Nimbostratus
Aug 09, 2005help with cookie expiration in iRule
I have two iRules listed below. We are injecting a cookie on siteA, the redirecting to siteB. SiteB checks for value set in siteA. If it is there allow user access. If not go back to siteA and get val...
Ted_Smith_11168
Nimbostratus
Aug 11, 2005This is in an internal QA Environment:
VIP uitaac.allied.nwie.net
when CLIENT_ACCEPTED {
set ckname uitaac1
set ckvalue [IP::client_addr]
set ckdomain .allied.nwie.net
set cookie [format "%s=%s; path=/; domain=%s" $ckname $ckvalue $ckdomain]
}
when HTTP_REQUEST {
set uri [HTTP::uri]
}
when HTTP_RESPONSE {
HTTP::respond 302 Location "https://uitaac1.allied.nwie.net$uri]" "Set-Cookie" $cookie
}VIP uitaac1.allied.nwie.net
when CLIENT_ACCEPTED {
set ckname uitaac1
set ckvalue [IP::client_addr]
set ckdomain .allied.nwie.net
}
when HTTP_REQUEST {
set uri [HTTP::uri]
if {[HTTP::cookie exists $ckname]} {
pool UITShared
}
else {
HTTP::redirect "https://uitaac.allied.nwie.net$uri"
}
}Thanks!
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
