Route Traffic between multiple pools based on Client IPs and XFF(same as Client IPs).
Hello Folks,
I have to divert the traffic between the Pool members based on the Client IPs and XFF headers(Contains the IPs same as condition 1).
I have created the IRule but still but I am facing issue with it.
Scenario :-
I have multiple websites some of them are coming from the WAF as source IP and some of them are landing directly to my F5 LTM, based on this condition I have created an IRule to match Client IPs either in Source address or in XFF. Rest of the traffic will land to default pool.
when HTTP_REQUEST {
if {( [class match [IP::client_addr] equals FED_ACCTEST_datagroup] ) } {
pool Federation-ACC-444
} elseif {( [class match [HTTP::header "Incap-Client-IP"] equals FED_ACCTEST_datagroup] ) } {
pool Federation-ACC-444
} else {
pool Fedration-ACC
}
}
Note :- In this IRULE only 3rd condition for the default pool is not working else everything is OK!