nextcloud/apps/files_sharing/lib/Controller
nfebe 8725129312 fix(sharing): Allow reasonable control 4 'Hide download' on fed shares
When creating public links from federated shares, users should be able to set
the 'Hide download' option independently as long as they are more restrictive
than the original share permissions.

Previously, the `checkInheritedAttributes` method was ignoring user preferences
and always overriding the hideDownload setting based solely on inherited
permissions, preventing users from disabling downloads even when the parent
share allowed them.

This fix implements some sort of inheritance logic:
- Users can only be MORE restrictive than parent shares, never LESS restrictive
- If parent hides downloads -> child MUST hide downloads (enforced)
- If parent allows downloads -> child can CHOOSE to hide or allow downloads
- If parent forbids downloads entirely -> child cannot enable downloads

Signed-off-by: nfebe <fenn25.fn@gmail.com>
2025-11-28 13:42:45 +01:00
..
AcceptController.php refactor(apps): Use constructor property promotion when possible 2024-10-21 12:37:59 +02:00
DeletedShareAPIController.php fix(files_sharing): Also list deleted team shares 2025-02-20 15:02:48 +00:00
ExternalSharesController.php chore: remove legacy action to test remote endpoint 2024-11-29 11:14:37 +01:00
PublicPreviewController.php fix(files_sharing): add mime fallback to public preview too 2025-06-28 09:27:20 +02:00
RemoteController.php fix(OpenAPI): Adjust array syntax to avoid ambiguities 2024-11-05 09:58:11 +01:00
SettingsController.php refactor(apps): Use constructor property promotion when possible 2024-10-21 12:37:59 +02:00
ShareAPIController.php fix(sharing): Allow reasonable control 4 'Hide download' on fed shares 2025-11-28 13:42:45 +01:00
ShareController.php fix(dav): allow multiple link shares token in session 2025-10-23 16:16:37 +02:00
ShareesAPIController.php fix(lookup-server): disable lookup server for non-global scale setups 2025-03-11 21:54:06 +01:00
ShareInfoController.php refactor(OpenAPI): Adjust scopes to match previous behavior 2025-01-06 14:30:40 +01:00