Hi,
With that sps filter, it will add the "X-Forwarded-For" header to the request that is sent to the backend. So you application can pickup the header from the request.
But also just warning, Remote_Addr which is what is used to fill that variable, will be the IP address of the physical address of the device that was the source of the previous socket connection that sent the request.
1) So if you have :
client -> SPS -> backend
The X-Forwarded-For address will contain the IP address of the client. (tick)
2) If you have :
client -> [ loadbalancer -> SPS -> backend ]
The X-Forwarded-For address will contain the IP address of the loadbalancer. (in this case you should be able to configure your loadbalancer to capture the client IP and place it in the X-Forwarded-For header.) (no-tick).
3) Also if you have
[client -> client firewall ] -> SPS -> backend
The X-Forwarded-For address will contain the IP address of the client firewall. (in this case the IP address of the "real" client is not obtainable). (small-tick)
Hope that helps, I described 2) and 3) as often the limitation of what can be obtained for the client IP address is misunderstood, and hope that makes it clear.
Cheers - Mark