From: <pri...@us...> - 2008-05-03 11:58:18
|
Revision: 5233 http://mantisbt.svn.sourceforge.net/mantisbt/?rev=5233&view=rev Author: prichards Date: 2008-05-03 04:58:11 -0700 (Sat, 03 May 2008) Log Message: ----------- LDAP port is ignored when using an URL for LDAP connection - as our example uses this format, remove the port. Modified Paths: -------------- trunk/mantisbt/config_defaults_inc.php trunk/mantisbt/core/ldap_api.php trunk/mantisbt/core/obsolete.php Modified: trunk/mantisbt/config_defaults_inc.php =================================================================== --- trunk/mantisbt/config_defaults_inc.php 2008-05-01 21:07:50 UTC (rev 5232) +++ trunk/mantisbt/config_defaults_inc.php 2008-05-03 11:58:11 UTC (rev 5233) @@ -927,7 +927,6 @@ # --- using openldap ------------- $g_ldap_server = 'ldaps://ldap.example.com.au/'; - $g_ldap_port = '636'; $g_ldap_root_dn = 'dc=example,dc=com,dc=au'; $g_ldap_organization = ''; # e.g. '(organizationname=*Traffic)' $g_ldap_uid_field = 'uid'; # Use 'sAMAccountName' for Active Directory Modified: trunk/mantisbt/core/ldap_api.php =================================================================== --- trunk/mantisbt/core/ldap_api.php 2008-05-01 21:07:50 UTC (rev 5232) +++ trunk/mantisbt/core/ldap_api.php 2008-05-03 11:58:11 UTC (rev 5233) @@ -29,13 +29,12 @@ # Connect and bind to the LDAP directory function ldap_connect_bind( $p_binddn = '', $p_password = '' ) { $t_ldap_server = config_get( 'ldap_server' ); - $t_ldap_port = config_get( 'ldap_port' ); if (!extension_loaded('ldap')) { trigger_error(ERROR_LDAP_EXTENSION_NOT_LOADED,ERROR); } - $t_ds = @ldap_connect ( $t_ldap_server, $t_ldap_port ); + $t_ds = @ldap_connect ( $t_ldap_server ); if ( $t_ds > 0 ) { $t_protocol_version = config_get( 'ldap_protocol_version' ); @@ -85,6 +84,7 @@ $t_ds = ldap_connect_bind(); $t_sr = ldap_search( $t_ds, $t_ldap_root_dn, $t_search_filter, $t_search_attrs ); + $t_info = ldap_get_entries( $t_ds, $t_sr ); ldap_free_result( $t_sr ); ldap_unbind( $t_ds ); Modified: trunk/mantisbt/core/obsolete.php =================================================================== --- trunk/mantisbt/core/obsolete.php 2008-05-01 21:07:50 UTC (rev 5232) +++ trunk/mantisbt/core/obsolete.php 2008-05-03 11:58:11 UTC (rev 5233) @@ -124,4 +124,5 @@ # changes in 1.2.0a1 config_obsolete( 'enable_relationship', '' ); + config_obsolete( 'ldap_port', 'ldap_server' ); ?> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |