Skip to content
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

Block overwriting mountpoints through COPY #4785

Merged
merged 1 commit into from
Aug 1, 2024

Conversation

kobergj
Copy link
Contributor

@kobergj kobergj commented Jul 31, 2024

reva part of owncloud/ocis#6999

@kobergj kobergj requested review from labkode, a team and glpatcern as code owners July 31, 2024 13:34
@kobergj kobergj force-pushed the FixPathCopies branch 2 times, most recently from 3d5f8b1 to fb07fe7 Compare July 31, 2024 13:46
@2403905
Copy link

2403905 commented Jul 31, 2024

Should you prevent the overwriting via the MOVE?

return nil
}

// we must not allow to override mountpoints - so we check if we have write access to the parent. If not this is a mountpoint
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

hm, what if we are in a readonly space where we were granted write permissions on a subfolder?

Copy link
Contributor Author

@kobergj kobergj Jul 31, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the comment is wrong - I only stat it, so view permissions is enough.

EDIT: updated the comment

@kobergj
Copy link
Contributor Author

kobergj commented Jul 31, 2024

Should you prevent the overwriting via the MOVE?

I don't think so. Cross-storage MOVEs are not supported as far as I know.

Signed-off-by: jkoberg <jkoberg@owncloud.com>
@kobergj kobergj merged commit c10f2ae into cs3org:edge Aug 1, 2024
9 of 10 checks passed
@kobergj kobergj deleted the FixPathCopies branch August 1, 2024 08:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants