From 0bd6ce10624f9bfcd464b9874ce15168de7c6b59 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Fri, 21 Nov 2008 02:15:47 +0000 Subject: [PATCH] ITS#4750 only read LDAP_CONF_FILE if geteuid() != getuid() --- libraries/libldap/init.c | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/libraries/libldap/init.c b/libraries/libldap/init.c index 4109b7eb74..d61ec89fbf 100644 --- a/libraries/libldap/init.c +++ b/libraries/libldap/init.c @@ -18,6 +18,10 @@ #include #include +#ifdef HAVE_GETEUID +#include +#endif + #include #include #include @@ -629,6 +633,12 @@ void ldap_int_initialize( struct ldapoptions *gopts, int *dbglvl ) #endif openldap_ldap_init_w_sysconf(LDAP_CONF_FILE); + +#ifdef HAVE_GETEUID + if ( geteuid() != getuid() ) + return; +#endif + openldap_ldap_init_w_userconf(LDAP_USERRC_FILE); { -- 2.39.5