Forum Discussion
Stanislas_Piro2
May 11, 2016Cumulonimbus
Hi,
In your VS 10.10.10.10 and APM-protected VS, you must configure universal persistence with JSESSIONID. both VS may use the same pool.
After authentication, extract JSESSIONID cookie from HTTP Auth response (VPE / Variable Assign):
session.custom.jsessionid =
expr { [lindex [regexp -inline {JSESSIONID=([^;\\\r]*)} [mcget session.http.last.response_cookie]] 1] }
Enable this irule on APM-protected VS to insert JSESSIONID in response after authentication:
when ACCESS_POLICY_COMPLETED {
if { ([ACCESS::policy result] equals "allow")} {
set jsessionid [ACCESS::session data get session.custom.jsessionid]
ACCESS::session data set session.user.sessiontype "ltm_apm"
ACCESS::respond 302 noserver Set-Cookie "JSESSIONID=$jsessionid;path=/;HttpOnly;secure" Location [ACCESS::session data get session.server.landinguri]
}
}