Daisuke_Kishimo
Mar 12, 2007Nimbostratus
I want to evaluate character string of Cookie by a hex digit.
Hello all.
I'm Japanese.I am weak in English.
But I do my best.
I want to evaluate character string of Cookie by a hex digit.
This cookie is "EX=......" by random of hex string.
A character is "0" to "f"
I wrote following iRule.
when HTTP_REQUEST {
if { [HTTP::header exist "cookie"] }{
switch [findstr [HTTP::cookie "cookie"] "EX" 3 1] {
"0" {
use pool A_pool
}
"1" {
use pool B_pool
}
"2" {
use pool C_pool
}
.
.
.
"f" {
use pool Q_pool
}
}
}
}
This Rule is a description to check 1 character.
But,I would like to check 2 character.
The case of "00" to "0f",use pool A_pool.
The case of "10" to "1f",use pool B_pool.
The case of "20" to "2f",use pool C_pool.
.
.
.
The case of "f0" to "ff",use poll Q_pool.
In this case, It is very troublesome that I write each.
Therefore I want to make the value that I acquired a number.
Can you achieve this problem?
Thanx and regards.