Configure Drupal login using LDAP / Active Directory
Overview
The Drupal LDAP Login module allows your LDAP / Window Active Directory users to login to Drupal using their LDAP / Active Directory (AD) credentials. This module also supports Windows auto-login based on currently logged-in Windows users using the NTLM and Kerberos authentication protocol. We provide a Drupal LDAP AD SSO login module compatible with Drupal 7, Drupal 8, Drupal 9, and Drupal 10.
The user’s LDAP Authentication can be performed on various LDAP servers like Microsoft Active Directory, OpenLDAP, Azure AD, JumpCloud, OpenDS, FreeIPA, Synology, and other Directory systems. Here we will go through the steps required to configure the LDAP Integration on your Drupal site. By the end of this guide your users can login to Drupal using their LDAP server credentials.
Installation Steps
- Using Composer
- Using Drush
- Manual Installation
Configuration Steps
Steps to Configure Drupal LDAP / Active Directory login module
- Once you enabled the module, navigate to Configuration ➔ miniOrange Active Directory / LDAP Integration as shown in the below image.
- Enter your LDAP/Active Directory server URL or IP address and click on the Contact LDAP Server button to test the connection. If you get any error, check troubleshooting.
- Enter the service account username and password and click on the Test Connection & Proceed button.
- Select the appropriate search base from the Search Base(s) dropdown. Users located within this search base will be able to log in to your Drupal site using their LDAP credentials.
- Select the username attribute from the Search Filter/Username Attribute dropdown. This is the LDAP attribute your LDAP users will use to log in to your Drupal website.
- Check the “Enable login with LDAP” checkbox to enable LDAP Authentication on your site.
- Check the Enable Auto-Registering of users in Drupal to automatically create your LDAP user's account in Drupal upon LDAP authentication if they do not already exist in Drupal.
- Click on Save & Next button.
- To enable Windows auto login using NTLM or Kerberos authentication protocol, Go to the NTLM & Kerberos tab, check the checkbox highlighted below, and click Save button to save your settings.
Test User LDAP Authentication
- Under the LDAP Configuration tab scroll down to the Test Authentication section.
- Enter your LDAP user’s username and password and click on the Test Authentication button. Remember, the username should match the LDAP attribute value you chose in the search filter dropdown.
- For example, if you selected 'uid' in the search filter, enter the 'uid' of your LDAP user as the username.
- After successful authentication, you will get a list of all LDAP attribute values associated with your user. From the Email Attribute dropdown select the LDAP attribute under which you get your user's email address and click on Save & Next button.
How to login to Drupal using LDAP credentials?
- Open a private/incognito window and go to your Drupal site login page.
- Enter the user's LDAP credentials. Remember, the username should match the LDAP attribute value you chose from the search filter dropdown.
After successful LDAP authentication, you will be able to access your Drupal site. If you face any error check the troubleshooting or reach out to us at drupalsupport@xecurify.com