Forum Discussion

Kumar_Thota's avatar
Kumar_Thota
Icon for Altocumulus rankAltocumulus
Feb 17, 2020
Solved

Accessing Different URI Paths in the same APM Session

We have an issue with the session. User hit a URI path abc.com/abc and opens a new tab and try out a different URI path in the same session with out logging in the previous session and we get the error " Access policy evaluation is already in progress for your current session" to counter this I have used an irule to kill the session.

 

when HTTP_REQUEST {

   if { ( [HTTP::cookie exists MRHSession] ) and not ( [ACCESS::session exists -state_allow [HTTP::cookie value MRHSession]] ) } {

       if { ( [HTTP::uri] ne [ACCESS::session data get session.server.landinguri] ) and not ( [ACCESS::session data get session.server.landinguri] eq "" ) } {

            [ACCESS::session remove ]

            HTTP::redirect [ACCESS::session data get session.server.landinguri]

       }      

   }

}

 

It tend to work on firefox properly but there is a problem with IE ( Error i get is page cannot be displayed) in Chrome there is a little bit latency where it flashes page cannot be displayed for few milli seconds before redirecting to the user to the new URI path.

 

F5 gurus need to help solving this problem. Any suggessions would be appreciated.

  • Fixed it if anyone are in the same situation this fix will work

    when HTTP_REQUEST {

      if { ( [HTTP::cookie exists MRHSession] ) and not ( [ACCESS::session exists -state_allow [HTTP::cookie value MRHSession]] ) } {

        if { ( [HTTP::uri] ne [ACCESS::session data get session.server.landinguri] ) and not ( [ACCESS::session data get session.server.landinguri] eq "" ) } {

      ACCESS::session remove

          HTTP::redirect [HTTP::uri]

          TCP::close

        }    

      }

    }

     

1 Reply

  • Fixed it if anyone are in the same situation this fix will work

    when HTTP_REQUEST {

      if { ( [HTTP::cookie exists MRHSession] ) and not ( [ACCESS::session exists -state_allow [HTTP::cookie value MRHSession]] ) } {

        if { ( [HTTP::uri] ne [ACCESS::session data get session.server.landinguri] ) and not ( [ACCESS::session data get session.server.landinguri] eq "" ) } {

      ACCESS::session remove

          HTTP::redirect [HTTP::uri]

          TCP::close

        }    

      }

    }