S0S0_251956
Oct 18, 2017Nimbostratus
URI Redirection with URI Allow
Hello I'm configuring LTM to redirect traffic for "/" to /frontend-web/app/auth.html and also I want to allow only URIs that contain /frontend-web/app/ and /frontend-web/api/ for that website. I configured data group and using below iRule, but redirection part is not working, when I'm accessing https://site.com connection is reset. Blocking part works fine. Can you help me with that ?
when HTTP_REQUEST {
if { [string tolower [HTTP::uri]] equals "/" } {
HTTP::redirect "https://[HTTP::host]/frontend-web/app/auth.html"
}
if { [ class match [string tolower [HTTP::uri]] contains uri_allow ] } {
return }
else {HTTP::respond 200 content "URL Blocked" }
}