Skip to content

feat: use pre-signed URLS for download from object storage - #65307

Merged
susnux merged 1 commit into
masterfrom
fix/pre-signed-urls
Oct 14, 2026
Merged

susnux merged 1 commit into
masterfrom
fix/pre-signed-urls

Conversation

@kristian-zendato

@kristian-zendato kristian-zendato commented Oct 8, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Download a single file in the Files app from object storage when the server provides a pre-signed URL.
The download action requests oc:downloadURL and nc:download-url-expiration for that file only. If the URL is present and not expired, the browser fetches it directly and skips the WebDAV HEAD, because the signature is for GET. Folders, multi-file downloads, and files without a direct URL still download through remote.php/dav.
This uses the existing WebDAV properties. The storage must have direct downloads enabled (use_presigned_url on the primary object store, or Enable Direct Downloads (presigned URLs) on an external S3 mount).

Checklist

AI (if applicable)

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

@kristian-zendato
kristian-zendato requested review from a team and skjnldsv as code owners October 8, 2026 07:43
@kristian-zendato
kristian-zendato requested review from pringelmann and susnux and removed request for a team October 8, 2026 07:43

@pringelmann pringelmann left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Seems good overall but after testing locally the downloads do not work as expected. Happy to approve though if I am missing something on my local setup.

Comment thread apps/files/src/actions/downloadAction.ts Outdated
Comment thread apps/files/src/actions/downloadAction.ts Outdated
@kristian-zendato
kristian-zendato requested a review from a team as a code owner October 8, 2026 14:22
@kristian-zendato
kristian-zendato requested review from Altahrim, CarlSchwan, leftybournes, pringelmann and salmart-dev and removed request for a team October 8, 2026 14:22
Comment thread apps/files/src/actions/downloadAction.ts Outdated
Comment thread apps/files/src/actions/downloadAction.ts Outdated
@susnux susnux changed the title fix: use pre-signed URLS for download from object storage feat: use pre-signed URLS for download from object storage Oct 13, 2026
Signed-off-by: kristian-zendato <kristian.zendato@nextcloud.com>
@susnux
susnux merged commit 7b51759 into master Oct 14, 2026
181 checks passed
@susnux
susnux deleted the fix/pre-signed-urls branch October 14, 2026 10:27
@susnux susnux mentioned this pull request Oct 14, 2026
@joshtrichards joshtrichards added the hotspot: file transfer performance upload & download performance related optimizations label Oct 16, 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 enhancement feature: object storage hotspot: file transfer performance upload & download performance related optimizations

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Use pre-signed URLs for downloading from object storage in web client

4 participants