Mike_Roe_60070
Nov 23, 2010Nimbostratus
APM irule: remote login page needs referer
Hi all, We have a need to hide all our apps behind a single login application and are using a remote login page in an APM policy to do this. The problem is that this login app needs some way of finding out which of our 500+ sites the request originated from. We were hopeful that we could just use the referer header but, as the firt hop in this process is the F5 VIP that the policy is assigned to the referer shows http://my.app.com/my.policy.
My best (and only) idea is to somehow attach a cookie in when the access session is created but, being a noob all I seem capable of is logging the original referer but I have been unsuccesful creating a cookie with that value in it that the remote login app can use. My attempt is below:
when ACCESS_SESSION_STARTED {
set orig_referer [HTTP::header value Referer]
log local0. "Referer: $orig_referer"
HTTP::cookie insert name "orig_referer_cookie" value $orig_referer path "/"
}
Any help making this one work would be very appreciated.