Forum Discussion
Tyson_James
Cirrus
Mar 15, 2018iRule to only allow traffic from US, Canada and private networks....
We have a current iRule that only accepts traffic from the US or private networks ( non-routable ). Shown below :
when CLIENT_ACCEPTED {
if {not ([whereis [IP::client_addr] country] eq "US") and ...
oguzy
Cirrostratus
Mar 15, 2018Hi Tyson,
You can try the below code:
when CLIENT_ACCEPTED {
if { not ([whereis [IP::client_addr] country] eq "US") and not ([whereis [IP::client_addr] country] eq "CA")} {
if { not ( [class match [IP::client_addr] equals private_net] ) } {
reject
}
}
}
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