Forum Discussion
SanjayP
Aug 26, 2021Nacreous
Hi,
Since you need to send some requests to backend as case-sensitive, you don't need to use a rediect but a rewrite funtion instead.
Please try below iRule. Selectively add the uri which needs to be send in lowercase to backend and update iRule accordingly. I would suggest you can create new iRule and attach to the VIP. From logging, you can see if the required uri has been converted to lowercase and disable it afterwards.
when HTTP_REQUEST {
switch -glob [string tolower [HTTP::uri]] {
"/cdn/img/test.png*" -
"/cdn/img/example.png*"
log local0. "original_uri: [HTTP::uri]"
{
set new_uri "[string tolower [HTTP::uri]]"
log local0. "new_uri: $new_uri"
HTTP::uri $new_uri
} default {
return
}
}
}