LDAP: resolve memberOf groups into auth.User.Groups (#17 follow-up) #40

Merged
Cordy merged 2 commits from feat/ldap-groups into main 2026-07-26 15:09:45 +00:00
Owner

Completes group resolution for the third auth mode: LDAP deployments now get /spaces/<group> and the /me groups field, same as OIDC.

  • bind returns the resolved groups: each memberOf value is reduced to its first RDN value (cn=eng,ou=groups,dc=…eng; AD's CN=Domain Admins,…Domain Admins); non-DN values (directories that store plain names) pass through as-is.
  • Cache fix: the verified-credentials cache previously returned the raw login string with no groups on hits — it now stores and returns the directory-resolved identity (canonical username + groups), so a cache hit is indistinguishable from a fresh bind.
  • Config comment for ldapGroupsAttr updated (it was still marked "future").

Tests: DN + plain-value group extraction, cached-path identity preservation, groupName unit cases (incl. AD-style multi-word CN).

Completes group resolution for the third auth mode: LDAP deployments now get `/spaces/<group>` and the `/me` groups field, same as OIDC. - `bind` returns the resolved groups: each `memberOf` value is reduced to its first RDN value (`cn=eng,ou=groups,dc=…` → `eng`; AD's `CN=Domain Admins,…` → `Domain Admins`); non-DN values (directories that store plain names) pass through as-is. - **Cache fix**: the verified-credentials cache previously returned the raw login string with no groups on hits — it now stores and returns the directory-resolved identity (canonical username + groups), so a cache hit is indistinguishable from a fresh bind. - Config comment for `ldapGroupsAttr` updated (it was still marked "future"). Tests: DN + plain-value group extraction, cached-path identity preservation, `groupName` unit cases (incl. AD-style multi-word CN).
Cordy merged commit 271bf5b0eb into main 2026-07-26 15:09:45 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Cordy/Cairn#40
No description provided.