lunitic_56137
Feb 14, 2013Nimbostratus
URI Query question
I have an environment that has 3 different uri conditions that contain a queries.
Scenario 1
If a uri query contains "foo", add "&bar" at the end, and send it to the foo_bar_pool
Scenario 2
If a uri query has "bar" already in it, send it to foo_bar_pool
Scenario 3
If the uri query has "USER-ID" in it send to user_pool.
So with that in mind, I put the following rule together:
when HTTP_REQUEST {
set uri_query [HTTP::query]
set bar_query "&bar"
log local0. [HTTP::uri]
if {$uri_query contains "bar"}{
log local0. "Found bar, [HTTP::query] Sending to foo_bar_pool "
pool foo_bar_pool
if {$uri_query contains "foo"} {
[URI::query [HTTP::query]$blogin_query]
pool foo_bar_pool
}
if {$uri_query containes "USER-ID"} {
pool user_pool
}
}
}
But I get nothing. What am I missing?