Letractively / mod-auth-external

Automatically exported from code.google.com/p/mod-auth-external
0 stars 0 forks source link

[Patch] conn_rec->remote_ip compilation failure with Apache 2.4.1 #8

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
The remote_ip field in the conn_rec structure was removed in Apache 2.4.1 and 
replaced with client_ip and useragent_ip.

See:
http://httpd.apache.org/docs/2.4/developer/new_api_2_4.html
http://svn.apache.org/viewvc/httpd/httpd/trunk/include/httpd.h?r1=1204968&r2=120
6291&diff_format=h
http://svn.apache.org/viewvc/httpd/httpd/trunk/include/httpd.h?r1=1211490&r2=121
4003&diff_format=h

Compilation of mod_authnz_external 3.3.1 fails with the following errors:

libtool --silent --mode=compile gcc -std=gnu99 -prefer-pic   -DLINUX=2 
-D_REENTRANT -D_GNU_SOURCE -g -O2 -pthread -c -o mod_authnz_external.lo 
mod_authnz_external.c && touch mod_authnz_external.slo
mod_authnz_external.c: In function 'exec_external':
mod_authnz_external.c:446: error: 'conn_rec' has no member named 'remote_ip'
mod_authnz_external.c:447: error: 'conn_rec' has no member named 'remote_ip'
apxs:Error: Command failed with rc=65536

This patch replaces accesses to remote_ip with client_ip.

Original issue reported on code.google.com by davidsansome on 26 Mar 2012 at 5:40

Attachments:

GoogleCodeExporter commented 8 years ago
http://httpd.apache.org/docs/2.4/developer/new_api_2_4.html kind of suggests to 
me that it should be r->useragent_ip instead, as I'm not sure the authenticator 
wants the address of a proxy.  The patch is equally obvious; attached for the 
record.

Original comment by cjwatso...@gmail.com on 9 Jul 2013 at 4:43

Attachments:

GoogleCodeExporter commented 8 years ago
I can confirm that davidsansome patch "0001-Apache-2.4-compatibility.patch" 
works when compiling with Apache 2.4.4. Otherwise, mod_authnz_external-3.3.1 
fails to compile with the following error message "mod_authnz_external.c:446: 
error: 'conn_rec' has no member named 'remote_ip'"

Original comment by ddarby...@iconicgroup.ca on 9 Jul 2013 at 8:34

GoogleCodeExporter commented 8 years ago
This fix will be in version 3.2.2

Thanks.

Original comment by j...@unixpapa.com on 11 Dec 2013 at 7:38