Forum Discussion
Cri
Nimbostratus
Jul 07, 2014Parsing redirect location uri
Hello team,
I've got this kind of problem: I have to complete an APM policy where users, after authentication process, have to be redirected on a specific uri that is defined dinamically in a go...
Kevin_Stewart
Employee
Jul 08, 2014Try this:
when HTTP_REQUEST {
if { ( [string tolower [HTTP::uri]] starts_with "/auth" ) and ( [ACCESS::policy result] equals "allow" ) } {
if { [URI::query [HTTP::uri] goto] ne "" } {
HTTP::redirect [URI::query [HTTP::uri] goto]
}
}
}
This will execute if the URI starts with "/auth" and the access policy evaluation is complete, so it should work in the initial request, and in any request after authentication.
Recent Discussions
Related Content
DevCentral Quicklinks
* 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
Discover DevCentral Connects