Forum Discussion
Client accessing both redirect and default pool in irule.
Working with the below irule. One of our app teams has complained that when the client is trying to access both the redirect and default pools as part of their of application, it fails. So what happens is their establishing a session, which takes them to the redirect pool, which works, but then the app sends them to the default pool, which fails. Any suggestions on what could be modified here?
when HTTP_REQUEST {
set usessl 0
switch -glob [HTTP::path] {
"/foo/bar/" -
"/foo/baa/" {
snat ~ip address~
set usessl 1
pool redirect-443 }
default {
set usessl 0
pool default-80
}
}
}
when SERVER_CONNECTED {
if { $usessl == 0 } {
SSL::disable
}
}
7 Replies
- Kevin_Stewart
Employee
First thing, you can probably streamline the iRule a little bit:
when HTTP_REQUEST { switch -glob [HTTP::uri] { "/foo/bar/_*" - "/foo/baa/_*" { snat automap pool redirect-443 } default { SSL::disable serverside pool default-80 } } }
Second thing is that it now depends on HOW it's failing. For instance, you left out the rest of the snat command in your sample code, so assuming you were pointing to Automap or a specific snat pool. Do you intend to not apply a snat for default pool traffic? What does the redirect look like?
- nitass
Employee
So what happens is their establishing a session, which takes them to the redirect pool, which works, but then the app sends them to the default pool, which fails.
does it work if client accesses to only the default pool?
- atoth
Cirrus
If the client accesses the redirect, it works fine, and it works fine if the client just accesses the default pool. Its only when the app tries to combine the two where its failing.
- nitass_89166
Noctilucent
Its only when the app tries to combine the two where its failing.
are you using oneconnect profile? if not, can you try?
sol7208: Overview of the OneConnect profile
- atoth
Cirrus
Are you suggesting using the default OneConnect profile? If not, what options should be used with it?
- nitass
Employee
Its only when the app tries to combine the two where its failing.
are you using oneconnect profile? if not, can you try?
sol7208: Overview of the OneConnect profile
- atoth
Cirrus
Are you suggesting using the default OneConnect profile? If not, what options should be used with it?
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