fix: check share owner permissions on public share access (#5888)

This commit is contained in:
kodareef5 authored and GitHub committed 2026-04-04 21:56:55 +02:00
1 parent 65a837de49
commit 7dbf7a3528
2 files changed
+40 -1

No files matched your search

+4
View File
@@ -33,6 +33,10 @@ var withHashFile = func(fn handleFunc) handleFunc {
return errToStatus(err), err
}
if !user.Perm.Share || !user.Perm.Download {
return http.StatusForbidden, nil
}
d.user = user
file, err := files.NewFileInfo(&files.FileOptions{