Skip to content

fix: disable direct download for shares - #52133

Merged
icewind1991 merged 1 commit into
masterfrom
no-shared-direct-download
May 8, 2025
Merged

fix: disable direct download for shares#52133
icewind1991 merged 1 commit into
masterfrom
no-shared-direct-download

Conversation

@icewind1991

Copy link
Copy Markdown
Member

I'm not aware of any storage backend that implements this but this still requires setting up the share source to forward the call currently.

Additionally I'm unsure if shares should even use the same direct download link as their source.

Signed-off-by: Robin Appelman <robin@icewind.nl>
@icewind1991icewind1991 added this to the Nextcloud 32 milestone Apr 11, 2025
@icewind1991
icewind1991 requested a review from a team as a code ownerApril 11, 2025 15:44
@icewind1991
icewind1991 requested review from artonge, provokateurin and yemkareems and removed request for a teamApril 11, 2025 15:44

@artongeartonge left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Not sure about the reason for such method in the first place. But isn't it the default anyway?

publicfunctiongetDirectDownload(string$path): array|false {
return [];
}

@icewind1991

Copy link
Copy Markdown
MemberAuthor

But isn't it the default anyway?

For storage wrappers, it defaults to forwarding the call to the underlying storage. Which for shared storage means doing the full share setup.

@icewind1991
icewind1991 merged commit 1228cfd into masterMay 8, 2025
@icewind1991
icewind1991 deleted the no-shared-direct-download branch May 8, 2025 13:14
@icewind1991

Copy link
Copy Markdown
MemberAuthor

/backport to stable31

Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to reviewWaiting for reviewsperformance 🚀

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants

@icewind1991@artonge@yemkareems@skjnldsv