02-Jun-2020 11:08
Hi,
We have requirement that in URI words contains "inventory" and "price" should forward else should reject.
the below irule is not working
when HTTP_REQUEST {
if { [string tolower [HTTP::host]] contains “price” or “inventory” } {
forward
} else { discard }
}
03-Jun-2020 00:09
Hi,
Can you try this:
when HTTP_REQUEST {
if { ([HTTP::uri] contains "inventory") || ([HTTP::uri] contains "price") } {
pool /your-pool
} else {
discard
}
}
Instead of pool you could also ure return and make sure your virtual server has a default pool.
Cheers,
Kees