#703: WebSession: detect proper client IP when behind load balancer
------------------------+-----------------
Reporter: simko | Owner:
Type: defect | Status: new
Priority: critical | Milestone:
Component: WebSession | Version:
Keywords: |
------------------------+-----------------
When we are behind an Apache `mod_proxy_balancer`, Invenio workers see the
IP address of the load balancer as the client IP. The balancer sets
however `X-Forwarder-For` HTTP header with the proper client IP.
We therefore need to amend session handler to set `req.remote_ip` properly
in these cases. For example, when `X-Forwarder-For` is set and when `X
-Forwarded-Server` and `X-Forwarded-Host` is coming really from
`CFG_SITE_URL`, then use this variable, otherwise use the standard
technique.
--
Ticket URL: <http://invenio-software.org/ticket/703>
Invenio <http://invenio-software.org>