inGroup and getUserGroups have different cache keys and implementations
Nobody has claimed this yet.
- Dominant language
- PHP
- Stars
- 17
- Forks
- 19
- Avg merge
- 11h 40m
- Merged PRs (30d)
- 2
Description
I'd expect Group_LDAP::inGroup to simply use Group_LDAP::getUserGroups or at least use the same cache keys.
This means that it could happen that the cache contains slightly different values, leading to bugs like https://github.com/owncloud/core/issues/26683 where one API which uses getUserGroups() sees that the user is member of a group, but inGroup says the user isn't.
@jvillafanez @owncloud/ldap
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading Group_LDAP::inGroup and Group_LDAP::getUserGroups, then compare how each constructs cache keys and obtains group membership. Check the linked core issue for the observed inconsistency and verify the relevant LDAP behavior. Done means both APIs return consistent membership results without divergent cached values.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- php
- Domain
- authorization
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100