Forum Discussion
Patrick_Chang_7
Feb 14, 2008Historic F5 Account
selective SNAT on Forwarding VS
I want to selectively SNAT on a forwarding VS based upon the IP address of the destination. My iRule would look like the following:
when CLIENT_ACCEPTED {
if [matchclass $$::internal_networks not equal IP destination] {
snatpool pool_snat
}
}
The questions I have are the following:
What is the syntax for not equal?
What structure should I use to get the IP of the destination in this case? Is it IP::local_addr?
- hoolio
Cirrostratus
Hi,when CLIENT_ACCEPTED { if {not ([matchclass $::internal_networks equals [IP::local_addr])}{ snatpool pool_snat } }
- Patrick_Chang_7Historic F5 AccountThanks
- Techgeeeg
Nimbostratus
I need a little bit of explanation what the above irule is doing. What I have understood is the following,
-
There is an address object "internal_networks" created under irule with the internal subnet defined.
-
The irule compares this subnet to the request coming to this VS and if it does not matches then it sends the connection from outbound_snat snat address pool. but if it matches what will happen then??
-
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