APM inactivity timeout redirect or notification page for LTM + APM connections
Background on this:
Have a customer that is publishing a Microsoft CRM instance behind APM and doing KCD with smart card auth. Access policy works fine, KCD works fine, web app works fine. The only problem we have is the inactivity timeout setting. Once the limit has been reached, the session is removed and content is no longer sent to the user in a very abrupt fashion. This is a problem because ALOT of the page is cached on the clients workstation and all they see is broken JPEGs and incomplete web content. Once they click around they are re authenticated but it is not pretty. I want to find a way to notify the user they have been inactive for a certain amount of time, send a HTTP 200 response with content notifying them with a link to click on to re authenticate. The option of increasing the inactive timeout is not an option due to their access session license limit. There would be alot of abandoned sessions that would aggregate potentially going over this limit.
I know with webtop and ssl vpn, you get a notification that you are about to be logged out due to inactivity but this doesn't seem to be available for LTM + APM policies.
This is what I have so far, there has to be a more efficient way of doing this though.
when ACCESS_SESSION_STARTED {
set ::EXPIRE "false"
}
when ACCESS_SESSION_CLOSED {
log local0. "Session has been closed"
set ::EXPIRE "true"
}
when HTTP_RESPONSE {
if {$::EXPIRE equals "true"} {
HTTP::respond 200 content "
You've Been Logged out due to inactivity
You have been logged out due to inactivity
Thanks for Using the application
Click to log back in.
"
}
}