Hi!,
I Need a IRule to redirect the connections of two ip’s to a pool, and other connections to another pool.
I tested with:
When HTTP_REQUEST {
if { [IP :: addr [IP :: client_addr ] equals xxxx ]} {
my pool pool_id
} Else if {[ IP:: addr [IP :: client_addr ] equals xxxx ]} {
my pool pool_id
}
}
No work, no redirects
The problem is that there is a proxy in the middle and translates the source addresses.
Need the same for a VS with port 443
I need Help! haha, please!
A. Diezma
nitass
November 14, 2011, 10:16am
2
No problem with “xff”. I will try.
thank you very much
Great! it works!
I applied:
When HTTP_REQUEST {
if {[HTTP:: header “X-Forwarded-For”] contains “x.x.x.164”} {
pool my_pool }
elseif {[HTTP:: header “X-Forwarded-For”] contains “x.x.x.167”} {
pool my_pool }
WEB} else {pool default_pool
}
Now I need another just to VS_port 443
Thanks a lot!!
Antonio
I also had to apply the profile http-xff
nitass
November 14, 2011, 11:31am
6
Don’t use xff for blocking, only for testing website
Again, thank you very much
Solved!
nitass
November 14, 2011, 11:49am
8
Don’t use xff for blocking, only for testing website sorry i did not explain well. actually, i just want to point how we parse x-forwarded-for header if there is more than one.