GIT Log for 2009-08-20 23:33 GMT
commit 48978c3e7f130d92c1acc52a14661354687ee05e Author: Alan T. DeKok <aland@freeradius.org> Date: Thu Aug 20 10:52:44 2009 +0200 Allow 100% to mean "read as fast as possible" Files changed: src/modules/frs_detail/frs_detail.c | 9 --------- 1 files changed, 0 insertions(+), 9 deletions(-) ====================================================================== commit fc1a8dc2665a2fdc897557f84d229b760d88d070 Author: Alan T. DeKok <aland@freeradius.org> Date: Wed Aug 12 17:14:28 2009 +0200 Fix minor issue Files changed: src/main/evaluate.c | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) ====================================================================== commit 6fe921d737d167af8063e472fc438e826a3ba032 Author: Alan T. DeKok <aland@freeradius.org> Date: Thu Aug 20 09:08:32 2009 +0200 Packet may not exist, so check for that, too Files changed: src/modules/rlm_attr_filter/rlm_attr_filter.c | 19 ++++++++++++------- 1 files changed, 12 insertions(+), 7 deletions(-) ======================================================================
hi, just a quick heads-up (until i check the GIT version and delve deeper) 2.1.6 doesnt compile on RHEL with default options Making all in rlm_ldap... gmake[6]: Entering directory `/usr/src/freeradius-server-2.1.6/src/modules/rlm_ldap' /usr/src/freeradius-server-2.1.6/libtool --mode=compile gcc -g -O2 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -Wall -D_GNU_SOURCE -DNDEBUG -I/usr/src/freeradius-server-2.1.6/src -I/usr/src/freeradius-server-2.1.6/libltdl -DHAVE_LDAP_START_TLS -DHAVE_LDAP_INITIALIZE -DHAVE_LDAP_INT_TLS_CONFIG -DLDAP_DEPRECATED -c rlm_ldap.c gcc -g -O2 -D_REENTRANT -D_POSIX_PTHREAD_SEMANTICS -Wall -D_GNU_SOURCE -DNDEBUG -I/usr/src/freeradius-server-2.1.6/src -I/usr/src/freeradius-server-2.1.6/libltdl -DHAVE_LDAP_START_TLS -DHAVE_LDAP_INITIALIZE -DHAVE_LDAP_INT_TLS_CONFIG -DLDAP_DEPRECATED -c rlm_ldap.c -fPIC -DPIC -o .libs/rlm_ldap.o rlm_ldap.c: In function `read_mappings': rlm_ldap.c:714: warning: passing arg 1 of `gettoken' from incompatible pointer type rlm_ldap.c: In function `ldap_connect': rlm_ldap.c:2224: warning: passing arg 2 of `ldap_set_rebind_proc' from incompatible pointer type rlm_ldap.c:2224: too many arguments to function `ldap_set_rebind_proc' rlm_ldap.c:2299: warning: implicit declaration of function `ldap_int_tls_config' gmake[6]: *** [rlm_ldap.lo] Error 1 gmake[6]: Leaving directory `/usr/src/freeradius-server-2.1.6/src/modules/rlm_ldap' gmake[5]: *** [common] Error 2 gmake[5]: Leaving directory `/usr/src/freeradius-server-2.1.6/src/modules' gmake[4]: *** [all] Error 2 gmake[4]: Leaving directory `/usr/src/freeradius-server-2.1.6/src/modules' gmake[3]: *** [common] Error 2 gmake[3]: Leaving directory `/usr/src/freeradius-server-2.1.6/src' gmake[2]: *** [all] Error 2 gmake[2]: Leaving directory `/usr/src/freeradius-server-2.1.6/src' gmake[1]: *** [common] Error 2 gmake[1]: Leaving directory `/usr/src/freeradius-server-2.1.6' make: *** [all] Error 2 Red Hat Enterprise Linux AS release 3 (Taroon Update 9) gcc (GCC) 3.2.3 20030502 (Red Hat Linux 3.2.3-59) Copyright (C) 2002 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. looks like some LDAP function isnt sane or the same with older versions. alan
hi, okay - looking further into this... LDAP headers etc changed a while back for some new functionality RHEL3 /usr/include/ldap.h LDAP_F( int ) ldap_set_rebind_proc LDAP_P(( LDAP *ld, LDAP_REBIND_PROC *ldap_proc)); random other box (but newer distro :) ) LDAP_F( int ) ldap_set_rebind_proc LDAP_P(( LDAP *ld, LDAP_REBIND_PROC *rebind_proc, void *params )); the FR code has been updated to use the new rebind argument....but this will fail on older systems. now, theres some autoconfig magic available to check for this...eg checking for ldap_set_rebind_proc... no checking whether ldap_set_rebind_proc takes 3 arguments... 3 looking at eg samba/pam_ldap and various other tools that use LDAP, this seems to be the required autoconf magic AC_CHECK_FUNCS(ldap_set_rebind_proc) AC_CACHE_CHECK(whether ldap_set_rebind_proc takes 3 arguments, $ac_cv_ldap_set_rebind_proc, [ AC_TRY_COMPILE([ #include <lber.h> #include <ldap.h>], [ldap_set_rebind_proc(0, 0, 0);], [$ac_cv_ldap_set_rebind_proc=3], [$ac_cv_ldap_set_rebind_proc=2]) ]) AC_DEFINE_UNQUOTED(LDAP_SET_REBIND_PROC_ARGS, $ac_cv_ldap_set_rebind_proc) I'm afraid at this point I can go no further than this...because my autoconf foo isnt that good at all....and when i tried putting this stuff into the rlm_ldap/configure.in I found that that file seems to be horrible broken in many other places (autoconf just breaks!) and my foo really is weak (and I cannot test all the ldap requirements either). anyway......I've fixed the code to compile on RHEL3 by making my own local wrapper code because autoconfigure doesnt (right now :-) ) nasty...but appears to work: --- freeradius-server/src/modules/rlm_ldap/rlm_ldap.c 2009-08-24 11:32:29.000000000 +0100 +++ freeradius-server-edit/src/modules/rlm_ldap/rlm_ldap.c 2009-08-24 14:13:19.000000000 +0100 @@ -98,6 +98,11 @@ #define REQUEST_REJECTED 2 #define MAX_CHALLENGE_LEN 128 +#define LDAP_SET_REBIND_PROC_ARGS 2 +/* for new LDAP libraries, we want this one instead */ +/* #define LDAP_SET_REBIND_PROC_ARGS 3 */ + + int radLdapXtnNMASAuth( LDAP *, char *, char *, char *, char *, size_t *, char *, int * ); #endif @@ -2218,11 +2223,19 @@ if (inst->chase_referrals) { rc=ldap_set_option(ld, LDAP_OPT_REFERRALS, LDAP_OPT_ON); - + +#if LDAP_SET_REBIND_PROC_ARGS == 3 if (inst->rebind == 1) { ldap_set_rebind_proc(ld, ldap_rebind, inst); } +#elif LDAP_SET_REBIND_PROC_ARGS == 2 + if (inst->rebind == 1) { + ldap_set_rebind_proc(ld, + inst); + } +#endif + } else { rc=ldap_set_option(ld, LDAP_OPT_REFERRALS, LDAP_OPT_OFF); alan
Alan Buxey wrote:
LDAP headers etc changed a while back for some new functionality
Arg...
I'm afraid at this point I can go no further than this...because my autoconf foo isnt that good at all....and when i tried putting this stuff into the rlm_ldap/configure.in I found that that file seems to be horrible broken in many other places (autoconf just breaks!) and my foo really is weak (and I cannot test all the ldap requirements either).
I've checked fixes into git. Please try that, or the "tar" file on http://git.freeradius.org/pre/ in a bit... Alan DeKok.
participants (3)
-
Alan Buxey -
Alan DeKok -
aland@deployingradius.com