Forum Discussion
ukitsysadmin_95
Nimbostratus
Aug 18, 2009Redirect accourding to source IP ranges
Referring to the previous post: http://devcentral.f5.com/Default.aspx?tabid=53&view=topic&postid=34863
I'm looking to create an iRule whereby visitors to a specific website are redirect...
Rob_13365
Altocumulus
Aug 20, 2009Hi
Spoke to soon about it working a treat. We cannot get the rule to work any more and need some clarification please.
our irule is thus:
when HTTP_REQUEST {
if {[matchclass [IP::client_addr] equals $::UK_Allowed_IP]}{
} else { HTTP::redirect http://redirect.test.com
}
}
The problems is that the irule is redirecting ALL traffic and seems to be ignoring the data group list.
We've tried the data group external file as a string - example:
"138.198.0.0/16",
"141.97.0.0/16",
"145.229.0.0/16",
"145.233.0.0/16",
and as an address - example
network 62.23.0.0/16,
network 62.24.32.0/19,
network 62.24.128.0/17,
network 62.30.0.0/16,
network 62.31.0.0/16,
Neither of these are being picked up. Could it be that the irule is looking for IP addresses rather than networks, so the list isn't matching the query?
Again, any help would be hugely appreciated,
Many thanks!
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
