Skip to content
Snippets Groups Projects
Commit 1f825dca authored by Maxime Besson's avatar Maxime Besson :wrench:
Browse files

Merge branch 'fix-remote-ip-3009' into 'v2.0'

Fix #3009

See merge request !385
parents 13400ea3 827e06e8
No related branches found
No related tags found
No related merge requests found
......@@ -26,6 +26,17 @@ Known regressions in the latest released version
None
2.18.0
------
Apache2 handler now uses IP from mod_remoteip
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
If you use `mod_remoteip <https://httpd.apache.org/docs/2.4/mod/mod_remoteip.html>`__ in your handlers,
LemonLDAP::NG will now correctly use the IP from ``mod_remoteip`` in
``$env->{REMOTE_ADDR}``.
2.17.1
------
......
......@@ -17,11 +17,8 @@ sub new {
my $env = {
#%ENV,
HTTP_HOST => $r->hostname,
REMOTE_ADDR => (
$r->connection->can('remote_ip') ? $r->connection->remote_ip
: $r->connection->client_ip
),
HTTP_HOST => $r->hostname,
REMOTE_ADDR => $r->useragent_ip,
QUERY_STRING => $args,
REQUEST_URI => $uri_full,
PATH_INFO => '',
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment