Forum Discussion
pedinopa_170325
Nimbostratus
Sep 14, 2016irule question
I want to write an iRule that will look at the client IP and direct the to a specific URL. I need some help with the irule
if CLIENT_IP -LIKE X.X.X.X
[
HTTP_REQUEST HTTP://SERVER/INDEX.HTM...
crodriguez
Sep 14, 2016Ret. Employee
You can also use the IP::addr command to check if an IP address is in a particular network range. For example:
if { [IP::addr [IP::client_addr] equals 10.10.10.0/24] } {
HTTP::redirect....
}
IP::client_addr is the same as IP::remote_addr on client-side events, such as HTTP_REQUEST.
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
DevCentral Quicklinks
* Getting Started on DevCentral
* Community Guidelines
* Community Terms of Use / EULA
* Community Ranking Explained
* Community Resources
* Contact the DevCentral Team
* Update MFA on account.f5.com
Discover DevCentral Connects