-
Notifications
You must be signed in to change notification settings - Fork 189
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
graph/sharing: Add check for role conditions #8247
Conversation
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
Keep this is draft as we need to bump reva for getting the other part of the fix: cs3org/reva#4462 Also, I am still trying to address the FIXME part about sharing space root (which requires the Owner condition) |
920c6f6
to
da31038
Compare
3bc99ad
to
26e7dc6
Compare
Co-Owner and Manager are space specific roles. They need the UnifiedRoleConditionOwner.
Use the condition from the unifiedrole to check if the requested role is actually applicable to the selected resource. Fixes: owncloud#8131
Don't try to assign space specific roles to file or directory shares in positive tests. The API now forbids those correctly. We might want to add negative tests for that.
When computing the allowed roles for a spaceroot use the correct conditions. Spaceroots require '@Subject.objectId Any_of @Resource.owners'. Note: Updating or deleting the permissions on a spaceroot via 'v1beta1/drives/{driveid}/items/{itemid}/permissions/{permissionid}' does still not work.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
Use the condition from the unifiedrole to check if the requested role is actually applicable to the selected resource.