OAuth 2.0 / OIDC Settings

These settings appear when you choose OAuth 2.0 / OIDC as the protocol. The Login behavior switches at the top of the form are shared with SAML.

Connection#


"Where dotCMS sends users to authenticate, and how it talks back to your IdP."

OIDC Connection section after discovery, showing the Configured by discovery panel, the Redirect URI with a copy button, and a stored client secret

FieldDescription
Discovery URLYour IdP's issuer or base URL, for example https://idp.example.com/oauth2/default, or the full /.well-known/openid-configuration URL. dotCMS adds the .well-known suffix only if it's missing. Click Discover to fetch the IdP's endpoints. On success, a read-only Configured by discovery panel lists the Issuer, Authorization, Token, JWKS, Userinfo, and Logout URLs.
Client IDFrom your IdP's application registration (sometimes called Application ID).
Client SecretEncrypted at rest. Once saved, it shows as Secret stored and cannot be read back. Click Replace to enter a new one. The secret stays on the dotCMS server, which sends it to the token endpoint using client_secret_basic; it never reaches the browser.
Redirect URIRead-only, with a copy button. Register this exact value as an authorized redirect URI in your IdP. It has the form https://<host>/api/v1/oauth/callback, where <host> should be the public hostname people actually use to reach dotCMS.

Advanced Configuration#


Expand Advanced configuration under the Connection section to see:

FieldDefaultDescription
External dotCMS URL (optional)—Overrides the public dotCMS URL used to build the redirect URI. For example, https://cms.example.com becomes https://cms.example.com/api/v1/oauth/callback. Use this behind proxies or to pin one redirect URI for a System-level configuration.
Issuer URLFilled by discoveryMust match the iss claim in tokens. Shown here only until discovery succeeds; after that it appears in the discovery panel.
Scopesopenid email profileSpace-separated. openid is required.
Groups URL (optional)—An endpoint dotCMS calls with the user's access token, for IdPs that can't put groups in token claims (for example Google Workspace or GitHub). Supports {email} and {sub} placeholders, which dotCMS fills from the user's verified claims.
Groups Response Path (optional)—A dot-path that picks group names out of the Groups URL response, with [] marking the array. Examples: memberships[].groupKey.id (Google Cloud Identity), groups[].email (Google Directory), [].slug (GitHub). Leave empty if the endpoint returns a plain JSON array of strings or {"groups": [...]}.

The OIDC form has no fields for entering endpoints by hand. dotCMS gets the authorization, token, userinfo, JWKS, and logout endpoints from discovery, so your IdP must publish a standard /.well-known/openid-configuration document.

Claim Mapping#


"Map id_token / userinfo claims to dotCMS user fields."

FieldDefaultDescription
EmailemailThe claim containing the user's email address. dotCMS uses it as the primary identifier.
Groups / roles claimgroupsThe claim containing group or role memberships, used for group-to-role mapping. This is often a custom claim; check your IdP's documentation.
First namegiven_name
Last namefamily_name

Provisioning and Role Mapping#


See User provisioning and role mapping.

Session Behavior#


FieldDescription
Logout URLFilled by discovery from the IdP's end_session_endpoint. When the IdP publishes one, signing out of dotCMS also ends the user's IdP session (OIDC RP-initiated logout). dotCMS also revokes the access token if the IdP has a revocation endpoint.

Google Workspace Groups#


Google doesn't put group memberships in its sign-in tokens, so dotCMS has to look them up after sign-in. When Discover returns Google's issuer (https://accounts.google.com), dotCMS offers to set this up.

The prompt is titled Google Workspace detected, and offers, "We can set up dotCMS to look up each user's groups from Google after they sign in, so group-to-role mappings work."

Choose Set up group lookup to fill in the following, then review the values under Advanced configuration and save. Only empty fields are filled.

Scopes               openid email profile https://www.googleapis.com/auth/cloud-identity.groups.readonly
Groups URL           https://cloudidentity.googleapis.com/v1/groups/-/memberships:searchDirectGroups?query=member_key_id=='{email}'
Groups Response Path memberships[].groupKey.id

Choose Not now to leave the form unchanged.

Google-side prerequisites. In your Google Cloud project:

  1. Enable the Cloud Identity API.
  2. Add the cloud-identity.groups.readonly scope to your OAuth consent screen.

If either is missing, sign-in fails. This is intentional: dotCMS never signs a user in with incomplete group information, because that could strip their roles. Group names returned by Google are group email addresses, so map those in Group → role mappings.

dotCMS follows Google's nextPageToken pagination, up to 20 pages by default (see OAUTH_GROUPS_MAX_PAGES).