mirror of
https://github.com/bitwarden/help
synced 2025-12-15 15:53:53 +00:00
5.6 KiB
5.6 KiB
layout, title, categories, featured, popular, hidden, tags
| layout | title | categories | featured | popular | hidden | tags | |
|---|---|---|---|---|---|---|---|
| article | Configuring directory sync with G Suite (Google) |
|
true | false | false |
This article will cover how to connect the bitwarden Directory Connector tool to your G Suite directory.
Requirements
- Read through the following article: [Syncing users and groups with a directory]({% link _articles/directory-connector/directory-sync.md %})
- Install bitwarden Directory Connector
- Using Directory Connector, log into your bitwarden account and select your enterprise organization
Table of Contents
- Create a Google Cloud Project
- Enable the Admin SDK API for Your Project
- Create & Configure a Service Account
- Configure G Suite Security
- Configure Directory Connector
- Testing
Create a Google Cloud Project
{% note %} If you already have a Google Cloud project available, you can skip this step and re-use it here. {% endnote %}
- Go to https://console.cloud.google.com
- Click Create Project {% image directory-connector/gsuite/create-project.png %}
- Enter a project name and click Create {% image directory-connector/gsuite/new-project.png %}
- Refresh the page and you should now see your project
Enable the Admin SDK API for Your Project
- Go to https://console.cloud.google.com
- Make sure the appropriate project is selected.
- Open the navigation menu and navigate to API Manager -> Dashboard.
- Select the Enable API button near the top. {% image directory-connector/gsuite/enable-api.png %}
- Click the Admin SDK link under the Google Apps APIs section. {% image directory-connector/gsuite/admin-sdk.png %}
- Click the Enable button near the top. {% image directory-connector/gsuite/admin-sdk-enable.png %}
Create & Configure a Service Account
- Go to https://console.cloud.google.com
- Make sure the appropriate project is selected.
- Open the navigation menu and navigate to API Manager -> Credentials.
- Click the Create credentials button and select Service account key. {% image directory-connector/gsuite/create-credentials.png %}
- Select New service account.
- Name the service account bitwarden Directory Connector. For the role, select Project and then Owner. Ensure that JSON is the selected Key type. Upon clicking Create, a JSON file will be downloaded; this is important for later so keep a note of where you have downloaded it. {% image directory-connector/gsuite/create-service-account.png %}
- You should now see your newly created service account listed. Click on Manage service accounts (on the right-hand side). {% image directory-connector/gsuite/click-manage-service-accounts.png %}
- Select the options button next to your service account, and select Edit. {% image directory-connector/gsuite/edit-service-account.png %}
- Check the box "Enable G Suite Domain-wide Delegation", enter anything for "Product name for the consent screen" and click Save. {% image directory-connector/gsuite/tick-gsuite.png %}
- Click View Client ID and you'll see the Client ID on screen. You will need the Client ID to configure security within G Suite. Highlight the Client ID and copy it to your clipboard. {% image directory-connector/gsuite/view-client-id.png %} {% image directory-connector/gsuite/copy-client-id.png %}
Configure G Suite Security
- Go to https://admin.google.com
- Open the navigation menu and navigate to Security.
- Select the API reference option and make sure Enable API access is checked. {% image directory-connector/gsuite/enable-api-access.png %}
- Back in the list of options, select Show more -> Advanced settings -> Manage API client access {% image directory-connector/gsuite/manage-api-access.png %}
- For Client Name, paste the Client ID of the service account that you created in the previous steps. For API Scopes, paste the following values to grant read-only access to users and groups:
https://www.googleapis.com/auth/admin.directory.user.readonly,https://www.googleapis.com/auth/admin.directory.group.readonly,https://www.googleapis.com/auth/admin.directory.group.member.readonly
- Click the Authorize button to save. {% image directory-connector/gsuite/authorize-client.png %}
- You should now see your service account listed as an authorized client of G Suite. {% image directory-connector/gsuite/authorized-client-list.png %}
Configure Directory Connector
- Locate the secret key JSON file that was downloaded whenever you created your service account in the steps above.
- Copy this file to the bitwarden Directory Connector program data folder at
C:/ProgramData/bitwarden/Directory Connector.- Optionally rename the JSON file to something that is easier to remember, such as
client_secret.json
- Optionally rename the JSON file to something that is easier to remember, such as
- Launch the Directory Connector console by double clicking the shortcut.
- Select option 3 (Configure directory connection) from the main menu.
- Select G Suite Directory as the type.
- Enter the name of the JSON file that you copied in step 2.
- Enter the domain of your G Suite account.
- Enter the email address of an admin user that has full access to the G Suite directory (such as your own).
Congrats! You are done configuring G Suite with the bitwarden Directory Connector.
Testing
Test your configurations by running a simulated directory sync. You should see your G Suite groups and/or users printed to the screen.