Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 132901 Details for
Bug 195079
sys-auth/pam_ldap doesn't work with multiple config files (at least not in one pam-config)
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
Modified pam_ldap
pam_ldap_183_different_configfiles.patch (text/plain), 1.75 KB, created by
Huemi
on 2007-10-08 11:05:47 UTC
(
hide
)
Description:
Modified pam_ldap
Filename:
MIME Type:
Creator:
Huemi
Created:
2007-10-08 11:05:47 UTC
Size:
1.75 KB
patch
obsolete
>--- /var/tmp/portage/sys-auth/pam_ldap-183/work/pam_ldap-183/pam_ldap.c 2006-10-19 15:22:27.000000000 +0200 >+++ pam_ldap.c.new 2007-10-06 16:04:58.000000000 +0200 >@@ -325,7 +325,8 @@ > void > nasty_ssl_hack (void) > { >- (void) dlopen ("/lib/security/pam_ldap.so", RTLD_LAZY); >+ /*Only to be able to use the old pam_ldap.so in case of need*/ >+ (void) dlopen ("/lib/security/pam_ldap2.so", RTLD_LAZY); > } > #endif /* HAVE_LDAPSSL_INIT */ > >@@ -2702,7 +2703,28 @@ > #if LDAP_SET_REBIND_PROC_ARGS < 3 > global_session = *psession; > #endif >+ /*It is possible that the config= option has been modified since the last >+ call. In this case the config-file should be reread and new values >+ should be used. >+ >+ For example I have two config-files with different servers and different >+ distinguished names. >+ >+ Might only make sense in conjunction with the pam_auth-php-module, but >+ for this I need it. >+ >+ Until I really understand how pam_ldap works, this is a quick and dirty >+ patch to force pam_ldap to reread the configFile. >+ >+ Hopefully I don't break other things by doing so ... >+ >+ I have the bad feeling that I'm creating a memory leak, because I don't >+ free the old session, but I haven't worked out how to do this. >+ */ >+ if (((session->conf->configFile!=NULL)&&(strcmp(configFile,session->conf->configFile) == 0)) >+ || ((session->conf->configFile==NULL)&&(configFile==NULL))) > return PAM_SUCCESS; >+ > } > > *psession = NULL; >@@ -3987,7 +4009,8 @@ > /* static module data */ > #ifdef PAM_STATIC > struct pam_module _modstruct = { >- "pam_ldap", >+/*Only to be able to use the old pam_ldap in case of need*/ >+ "pam_ldap2", > pam_sm_authenticate, > pam_sm_setcred, > pam_sm_acct_mgmt,
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 195079
: 132901 |
132903
|
132905