Forum Discussion
iRule for Snat pool association
Ok Thanks for the answers. Now i have another question...if i want to parse the IP address and pass it to snat address like this :
192.168.0.0--> 10.168.x.x
How can i implement it?
when CLIENT_ACCEPTED { set xyz [findstr [IP::client_addr] 4 ] ltm data-group internal SnatAddress { records { 192.168.0.0/24 {} 192.168.1.0/24 {} 192.168.3.0/24 {} 192.168.6.0/24 {} 192.168.11.0/24 {} 192.168.12.0/24 {} 192.168.13.0/24 {} 192.168.30.0/24 {} 192.168.40.0/24 {} 192.168.200.0/24 {} 192.168.254.0/24 {}
}
type ip
}
Check if the client IP address is a member of the address data group named Hosts
if { [matchclass [IP::client_addr] equals SnatAddress]} {
set xyz "dieci"
switch $xyz {
"dieci" { snat 10.$xyz }
}
}
else { discard } } return
}
}
Default action is to not SNAT
snat none
Is it possible?
Help guide the future of your DevCentral Community!
What tools do you use to collaborate? (1min - anonymous)Recent Discussions
Related Content
* 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