Skip to content

allow every with direct access to a shared file to modify all shares for the file - #63036

Open
icewind1991 wants to merge 4 commits into
masterfrom
unified-sharing-native-owner
Open

allow every with direct access to a shared file to modify all shares for the file#63036
icewind1991 wants to merge 4 commits into
masterfrom
unified-sharing-native-owner

Conversation

@icewind1991

@icewind1991 icewind1991 commented Aug 7, 2026

Copy link
Copy Markdown
Member

Summary

Allow all users that have direct (not through a share) access, and share permissions to a file access to see and modify all shares for that file, even ones created by other users.

Non-owner are still unable to change the share sources, as modifying the share sources can impact who has "direct" access to the share. Which adds a whole list of potential issues.

This mirrors the existing logic around IShareOwnerlessMount, but makes the behavior work automatically instead of mounts having to opt-in. Afaik this is equivilent since all mounts I'm aware of that this behavior would trigger for (external storage, groupfolders) opt-in to IShareOwnerlessMount.

Edit: switched to to still require the explicit mount opt-in

  • Return shares owned by others when listing shares for a specific file
  • Allow modifications to the returned shares

Requires

Checklist

AI (if applicable)

  • The content of this PR was partly or fully generated using AI

@icewind1991 icewind1991 added this to the Nextcloud 35 milestone Aug 7, 2026
@icewind1991 icewind1991 added the 2. developing Work in progress label Aug 7, 2026
@icewind1991 icewind1991 changed the title [WIP] allow a [WIP] allow every with direct access to a shared file to modify all shares for the file Aug 7, 2026
@icewind1991
icewind1991 force-pushed the unified-sharing-native-owner branch 8 times, most recently from b6e04d8 to fb0fc5e Compare August 12, 2026 19:53
# This is the 1st commit message:

feat: allow users with "native" access to see all shares of a file

Signed-off-by: Robin Appelman <robin@icewind.nl>

# Conflicts:
#	lib/unstable/Sharing/Source/IShareSourceType.php
#	tests/lib/Sharing/AbstractSharingManagerTests.php

# Conflicts:
#	lib/private/Sharing/SharingBackend.php
#	tests/lib/Sharing/AbstractSharingManagerTests.php

# The commit message #2 will be skipped:

# fixup! feat: allow users with "native" access to see all shares of a file
Signed-off-by: Robin Appelman <robin@icewind.nl>
Signed-off-by: Robin Appelman <robin@icewind.nl>
Signed-off-by: Robin Appelman <robin@icewind.nl>
@icewind1991
icewind1991 force-pushed the unified-sharing-native-owner branch from fb0fc5e to 74aa092 Compare August 14, 2026 16:16
@icewind1991 icewind1991 added 3. to review Waiting for reviews and removed 2. developing Work in progress labels Aug 14, 2026
@icewind1991
icewind1991 marked this pull request as ready for review August 14, 2026 16:17
@icewind1991
icewind1991 requested a review from a team as a code owner August 14, 2026 16:17
@icewind1991
icewind1991 requested review from Altahrim, leftybournes, provokateurin and salmart-dev and removed request for a team August 14, 2026 16:17
@icewind1991

Copy link
Copy Markdown
Member Author

I think this is "ready"

@icewind1991 icewind1991 changed the title [WIP] allow every with direct access to a shared file to modify all shares for the file allow every with direct access to a shared file to modify all shares for the file Aug 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant