0

I have a TestLink webservice running on a server, and OpenLDAP running on other server. There are no firewall problems between them (I managed to configure Redmine, on the same server as TestLink, to use LDAP authentication).

But whenever I place the configuration for LDAP in TestLink, TestLink stops working. I have no clue on what is happening.

This is where I define LDAP's settings on custom_config.inc.php:

$tlCfg->authentication['method'] = 'LDAP';
$tlCfg->authentication['ldap_server'] = 'serverip';
$tlCfg->authentication['ldap_port'] = '389';
$tlCfg->authentication['ldap_version'] = '2';
$tlCfg->authentication['ldap_root_dn'] = 'dc=mycompany,dc=com,dc=br';
$tlCfg->ldap_organization'] = '';
$tlCfg->authentication['ldap_uid_field'] = 'uid';
$tlCfg->authentication['ldap_bind_dn'] = 'myuser'; //Not actual login name and password, for obvious reasons
$tlCfg->authentication['ldap_bind_passwd'] = 'mypassword';
$tlCfg->authentication['ldap_tls'] = false;
$tlCfg->user_self_signup = true;

I'm certain that OpenLDAP is 2.X. My TestLink version is 1.9.3

What could I be doing wrong?

1
  • 2
    Post the access log from the TestLink and also from the directory server. Also, don't use LDAPv2, use LDAPv3 (ldap_version). Sep 23, 2012 at 19:06

1 Answer 1

0

I solved it. There were some dumb little errors.

First, as @Terry Gardner pointed out, I should use LDAPv3:

$tlCfg->authentication['ldap_version'] = '3';

Second, this line was wrong:

$tlCfg->ldap_organization'] = '';

The correct version would be:

$tlCfg->authentication['ldap_organization'] = '';

And finally, on /etc/php.ini I added

extension=ldap.so

For doing this, I needed to install the php-ldap package from yum.

yum install php-ldap
1
  • I have everything correct as you mentioned. I kept bind_dn and bind_passwd fields blank. When I try to login using ldap user, it says - ldap_bind(): Unable to bind to server: Confidentiality required. Any thoughts? Apr 6, 2017 at 9:54

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .