-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exclude group backend from showing groups in users page (post-filter approach) #27184
Conversation
@PVince81, thanks for your PR! By analyzing the history of the files in this pull request, we identified @DeepDiver1975, @bartv2 and @speijnik to be potential reviewers. |
looks like this doesn't exclude from the provisioning API, grrrr |
Maybe include some methods such as Section would refer to well known sections such as "users_page", "sharing_dialog", "provisioning_api", etc. and the user would be the user who wants to fetch the groups (some users shouldn't see some groups) The different backends would implement this new visiblity method. I'm not sure if this is a good idea because this might work fine for specific sections, but the backends should know all possible sections, so usage by 3rdparty apps will be difficult. |
I don't think we can do this smoothly. If we opt for a breaking change, at least we should make sure the change is extensible enough to not need any additional change for a very long time. |
@jvillafanez thanks for helping to advance the thought process. This is a nice starting point. My problem currently is that it's not really a "visible group" by itself. Here are a few cases:
Now since custom groups are basically only to be used for sharing, maybe I could make all backend methods empty so they never return anything. Then add a new method |
I'm going to try out the above proposal, there is a bit of chance that it might work. I only found one code path for the share autocomplete. However if we want to be strict about validation, we'll also need to tweak the share manager to not allow creating direct shares with groups not returned by |
If we have a base class |
@jvillafanez while this sounds like it makes sense, the |
I'm starting to get a feeling that we're abusing the "group backend" thing for the sake of custom groups. The other approach is more complicated unfortunately: it requires to implement:
|
@jvillafanez PR with the "getUserGroupsForSearch" approach: owncloud/customgroups#25 I'm not happy with that one either, but at least it works and properly hides the groups from management APIs. |
Obsoleted by the better #27287 |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Description
Some group backends are providing groups only for the share dialog like the customgroups app.
This PR provides a somewhat clumsy way to exclude these from the users page and provisioning API.
Related Issue
owncloud/customgroups#6
Motivation and Context
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist:
Notes
The approach is not good as it also excludes LDAP groups because it relies on the "can this backend manage group memberships" attribute.
We might need a new attribute (but then all old backends must implement it) or a new interface + method to check whether groups can be managed.
@jvillafanez @DeepDiver1975 any advice ?