Latest articles
Latest articles of category




LDAP user authentication


If you running any version of OpenLDAP or Fedora Directory Server you will need just 3 minutes to setup LDAP authentication with Guru CMS.

The only part of the code that you need to update to include your LDAP server details is outlined below.

LDAP settings
 
ldap_set_option($ds, LDAP_OPT_PROTOCOL_VERSION, 3);
$server='ldap://yourserver:389 ldap://yoursecondaryldapserver:389';
$admin='uid=authenticate,ou=System,dc=domain,dc=edu,dc=org';
$passwd='yourpassword';

The above settings must sent to us in order to setup the relevant file ldapAuth.php and then encode it using Ioncube.
After that installation is simply by enabling the module under the administration control panel.

There is always a free of charge installation from Guru-host if you prefer.

To summarize, all the info that we need is:

Your LDAP protocol version: 2 or 3 for example
Your primary LDAP server and running port (389 normal or 636 if running under SSL): like yourdomain.com:636
A user with access to read the whole directory
The password of that user.

The last step is to run the shareUsers.php from terminal or via cron to sync your LDAP user base to Guru CMS.
just type from terminal: php /full/path/to/shareUsers.php and then add that to your cron to run 1 or more times per day depending the LDAP database you have.

Posted on: 17/06/2016