mirror of
https://github.com/pocket-id/pocket-id.git
synced 2026-02-05 00:39:38 +03:00
🐛 Bug Report: (LDAP) Checking membership for admin group is inconsistent with populating group memberships #624
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @chipschipschips on GitHub (Jan 24, 2026).
Reproduction steps
This sets up an LDAP account
testadminand LDAP grouppocketid.admin.pocketid.adminwill be the PocketID admin group.testadminuser account in LDAPmemberOfattribute for thepocketid.admingrouppocketid.admingroup in LDAPmemberattribute for thetestadminuserLDAP_ADMIN_GROUP_NAMEtopocketid.adminFull repro is available here.
Expected behavior
testadminuser should have admin privileges in PocketIDis_adminfield in theuserstable should be set totrueActual Behavior
testadminuser does not have admin privileges in PocketIDis_adminisfalsein theuserstable in the databasetestadminuser does show as a member of thepocketid.admingroup in themembershiptable in the databasePocket ID Version
v2.2.0
Database
SQLite and Postgres 18.
OS and Environment
Docker compose on Docker Desktop for macOS, served using Traefik.
Log Output
Logs don't show anything interesting.
@chipschipschips commented on GitHub (Jan 24, 2026):
I think the problem is here in
SyncUsers, where it checks for membership of the admin group by looking only at thememberOfattributes on the user object.Contrast this to how group membership is established in
SyncGroups, where it looks at the member attributes in the group to populate the membership table.