Group Mapping - OAuth & OIDC Login
Last updated on
4 December 2025
Group Mapping
This feature allows you to map roles/groups received from your OAuth Provider to your existing groups in Drupal. To enable this feature, you first need to install and activate the Group module on your Drupal site.
Prerequisite:
- Install and activate the OAuth & OpenID Connect Login - OAuth2 Client SSO Login module on your Drupal site. Follow these steps to install the module.
Add Group type and Group to Drupal site
- After installing the modules you can see Groups in the menu bar. Navigate to the Groups tab and start creating groups.
- Click the +Add group button. If you do not have any group type then first you will be asked to create a group type.
- Click the Add new group type link.
- Enter the name in the Name text field and the title in the Title field label text box under the Group settings section.
- Click the Save group type button.

- Now, Navigate to the List tab and click on +Add group button.

- Enter the name in the text Maintainers text box, click on Create site maintainers and complete your membership button.
- In the next step enter URL alias in URL alias text box and click on the Save group and membership button.
- You successfully created a group.

Configure Group Mapping
- Now, navigate to the Edit tab, under the Client Configuration tab.
- In the Edit tab, under the Group Mapping section, check the Enable Group Mapping checkbox. It is mandatory for group mapping.

- Enter the attribute name through which you receive the user groups from your OAuth provider, and specify this attribute in the Group Attribute text field.

- Select the Drupal Group Name from the dropdown list and enter the received attribute value in the OAuth Server Group Name/ID text box.
- Click on the Save Configuration button.

Let’s see how Group Mapping works:
- Open an incognito window / new browser. Navigate to the Drupal site login page and log in with the provider name link.
- Now, navigate to the Groups tab and click on the group name link.
- Navigate to the Members tab. You can see the member added from the OAuth server.

Help improve this page
Page status: No known problems
You can:
You can:
- Log in, click Edit, and edit this page
- Log in, click Discuss, update the Page status value, and suggest an improvement
- Log in and create a Documentation issue with your suggestion