Admin ConsoleUser Management

Sync with Active Directory or LDAP

This article will help you get started using Directory Connector to sync users and groups from your LDAP or Active Directory service to your Bitwarden organization. Bitwarden provides built-in connectors for the most popular LDAP directory servers, including:

  • Microsoft Active Directory

  • Apache Directory Server (ApacheDS)

  • Apple Open Directory

  • Fedora Directory Server

  • Novell eDirectory

  • OpenDS

  • OpenLDAP

  • Sun Directory Server Enterprise Edition (DSEE)

  • Any generic LDAP directory server

Connect to your server

Complete the following steps to configure Directory Connector to use your LDAP or Active Directory:

  1. Open the Directory Connector desktop app.

  2. Navigate to the Settings tab.

  3. From the Type dropdown, select Active Directory / LDAP.

    The available fields in this section will change according to your selected type.

  4. Configure the following options:

Configure sync options

tip

When you are finished configuring, navigate to the More tab and select the Clear Sync Cache button to prevent potential conflicts with prior sync operations. For more information, see Clear Sync Cache.

Complete the following steps to configure the settings used when syncing using Directory Connector:

note

If you are using Active Directory, many of these settings are predetermined for you and are therefore are not shown.

  1. Open the Directory Connector desktop app.

  2. Navigate to the Settings tab.

  3. In the Sync section, configure the following options as desired:

Specify sync filters

User and group filters can be in the form of any LDAP-compatible search filter.

Active Directory provides some advanced options and limitations for writing search filters, when compared to standard LDAP directions. Learn more about writing Active Directory search filters here.

note

Nested groups can sync multiple group objects with a single referent in the Directory Connector. Do this by creating a group whose members are other groups.

Samples

To filter a sync for all entries that have objectClass=user and cn (common name) that contains Marketing:

Bash
(&(objectClass=user)(cn=*Marketing*))

(LDAP-only) To filter a sync for all entries with an ou (organization unit) component of their dn (distinguished name) that is either Miami or Orlando:

Bash
(|(ou:dn:=Miami)(ou:dn:=Orlando))

(LDAP-only) To exclude entities that match an expression, for example all ou=Chicago entries except those that also match a ou=Wrigleyville attribute:

Bash
(&(ou:dn:=Chicago)(!(ou:dn:=Wrigleyville)))

(AD Only) To filter a sync for users in the Heroes group:

Bash
(&(objectCategory=Person)(sAMAccountName=*)(memberOf=cn=Heroes,ou=users,dc=company,dc=com))

(AD Only) To filter a sync for users that are members of the Heroes group, either directly or via nesting:

Bash
(&(objectCategory=Person)(sAMAccountName=*)(memberOf:1.2.840.113556.1.4.1941:=cn=Heroes,ou=users,dc=company,dc=com))

Test a sync

tip

Before testing or executing a sync, check that Directory Connector is connected to the right cloud server (e.g. US or EU) or self-hosted server. Learn how to do so with the desktop app or CLI.

To test whether Directory Connector will successfully connect to your directory and return the desired users and groups, navigate to the Dashboard tab and select the Test Now button. If successful, users and groups will be printed to the Directory Connector window according the specified sync options and filters:

Test sync results
Test sync results

Start automatic sync

Once sync options and filters are configured and tested, you can begin syncing. Complete the following steps to start automatic syncing with Directory Connector:

  1. Open the Directory Connector desktop application.

  2. Navigate to the Dashboard tab.

  3. In the Sync section, select the Start Sync button.

    You may alternatively select the Sync Now button to execute a one-time manual sync.

Directory Connector will begin polling your directory based on the configured sync options and filters.

If you exit or close the application, automatic sync will stop. To keep Directory Connector running in the background, minimize the application or hide it to the system tray.

note

If you're on the Teams Starter plan, you are limited to 10 members. Directory Connector will display an error and stop syncing if you try to sync more than 10 members.

This plan is no longer available for purchase. This error does not apply to Teams plans.

Sync with Active Directory troubleshooting

Value limit reached when synchronizing from an Active Directory instance:

The Active Directory MaxValRange has a default setting of 1500. If an attribute, such as members on a Group has more than 1500 values, Active Directory will return both a blank members attribute, as well as a truncated list of members on separate attributes, up to the value of MaxValRange.

  • You can adjust the MaxValRange policy to a value higher than the number of members of your largest group in Active Directory. See the Microsoft documentation for setting Active Directory LDAP policies by using the ntdsutll.exe utility.

Suggest changes to this page

How can we improve this page for you?
For technical, billing, and product questions, please contact support