From: Glenn H. <ghe...@al...> - 2004-01-07 03:09:06
|
On Oct 23, 2003, at 1:50 PM, JAmes Atwill wrote: > Hello, > > I'm currently in the process of integrating Mantis with our local LDAP > directory. > > The attached diff file makes the following changes: > > - Create User: UI won't ask for password if using LDAP, won't ask for > email address if use_ldap_email is on. The current patch > puts 'using_ldapNNNNN' (where N is a series of random numbers) for a > password in the database. > > - Manage User: Will lookup the users email address in the LDAP > directory > if use_ldap_email. > > - Core/LDAP: uses the 'mail' attribute, not the 'email' attribute > > These patches (against HEAD) presume the administrator has pre-made the > user in the LDAP directory using an external tool (such as > phpldapadmin) > and simply wants to use the common attributes (email, password, name, > etc) for Mantis. I believe this is likely the most common scenario > for > most people. > > Comments? > There is one more thing to patch. In the welcome message, the user is given a password that won't work. My patch to core/email_api.php follows. Note that I also have applied my own patch to add NIS lookup functionality (posted to this list November 13, 2003). 297a310,312 > $t_ldap = ( LDAP == config_get( 'login_method' ) ); > $t_nis = ( NIS == config_get( 'login_method' ) ); > 310,312c325,330 < lang_get( 'new_account_username' ) . $v_username . "\n". < lang_get( 'new_account_password' ) . $p_password . "\n\n". < lang_get( 'new_account_message' ) . --- > lang_get( 'new_account_username' ) . $v_username . "\n"; > if ( !$t_ldap && !$t_nis ) { // don't print password for LDAP and NIS as we can't > // change it from inside mantis > $t_message .= lang_get( 'new_account_password' ) . $p_password . "\n\n"; > } > $t_message .= lang_get( 'new_account_message' ) . -- Glenn Henshaw Altera Ottawa Technology Center Phone: (613) 591-6702 Email: ghe...@al... |