Are you using "Route Domains? If so, it’s probably your error. Example from one of my irule; set userip [getfield [IP::client_addr] “%” 1] switch -glob -- $userip { “10.10.10.*” - “10.10.11.*” - “10.10.13.*” { Do what you want! } default { the default }}
Yes, Steph. I did that. The remote_addr value is my correct ip address with %1 at the end. (1.1.1.1%1). But TCL keep telling me that the command is invalid, while executing "client_ip equal “1.1.1.1"”
IP address comparisons were discussed quite thoroughly in this old DevCentral post. Pay particular attention to the first comment, which discusses how to strip the route domain indicator from the test address.