From 1451be9ded7f666f1fcd42ad957e2a7aad992c09 Mon Sep 17 00:00:00 2001 From: Peter Bieringer Date: Tue, 24 Feb 2026 06:45:16 +0100 Subject: [PATCH] sharing: add support for put --- radicale/app/put.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/radicale/app/put.py b/radicale/app/put.py index 9ab87c94..4e62ec1d 100644 --- a/radicale/app/put.py +++ b/radicale/app/put.py @@ -182,6 +182,15 @@ class ApplicationPartPut(ApplicationBase): path: str, user: str, remote_host: str, remote_useragent: str) -> types.WSGIResponse: """Manage PUT request.""" permissions_filter = None + if self._sharing._enabled: + # Sharing by token or map (if enabled) + sharing = self._sharing.sharing_collection_resolver(path, user) + if sharing: + # overwrite and run through extended permission check + path = sharing['PathMapped'] + user = sharing['Owner'] + permissions_filter = sharing['Permissions'] + access = Access(self._rights, user, path, permissions_filter) access = Access(self._rights, user, path, permissions_filter) if not access.check("w"): return httputils.NOT_ALLOWED