Forum Discussion
APM Open a second startup browser after the webtop portal launch
Okay, I'm going to file this one under oddball configs, but I think I have something that will work. Tested on 11.5 so your mileage may vary.
The basic config is a layered set of VIPs: external LTM HTTPS VIP with SSL offload, generic STREAM profile, and an iRule, and internal APM HTTP VIP with webtop and portal configuration. You can still set the secure flag in the access policy because the external interface is HTTPS.
client -> LTM VIP -> APM VIP
And now the iRule (applied at the external LTM VIP):
when HTTP_REQUEST {
STREAM::disable
if { [HTTP::uri] starts_with "/vdesk/webtop.eui?webtop=" } {
if { [ACCESS::session data get -sid [HTTP::cookie value MRHSession] session.custom.trigger] ne 1 } {
set catch 1
ACCESS::session data set -sid [HTTP::cookie value MRHSession] session.custom.trigger 1
}
}
virtual simple-vs
}
when HTTP_RESPONSE {
if { [info exists catch] } {
unset catch
STREAM::expression {@@ @}
STREAM::enable
}
}
The idea is this:
-
If the URI starts with "/vdesk/webtop.eui?webtop=", a standard webtop invocation, check the value of a custom session variable. If it's already set, do nothing. If it isn't set, create a temporary "catch" variable. The session variable prevents the second tab from opening multiple times.
-
Use the virtual command in the HTTP_REQUEST to send the traffic to the internal APM VIP.
-
In the HTTP_RESPONSE event, if the catch variable exists, unset it and then use the STREAM profile to add a little piece of JavaScript to the end of the webtop document. In this case it's the "F5_Invoke_open" function that's normally used to launch links within the webtop. The only thing you need to change here is the URL that it's going to open. You can use the real value or the obfuscated URL. Either appear to work. Also, because you'll be using JavaScript to open a window without user intervention, most browsers will see that as a popup and warn you, so you'd need to set this as a trusted site to prevent that warning message.
And of course you may still need to alter to fit your exact use case.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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