From 7874dc62eac95674483836b7e19f6f6ac4763138 Mon Sep 17 00:00:00 2001 From: Peter Bieringer Date: Sat, 14 Mar 2026 07:25:26 +0100 Subject: [PATCH] sharing/property-overlay: permit and replace displayname --- radicale/app/propfind.py | 4 ++++ radicale/sharing/__init__.py | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/radicale/app/propfind.py b/radicale/app/propfind.py index 7d0ee59f..d5260d5c 100644 --- a/radicale/app/propfind.py +++ b/radicale/app/propfind.py @@ -312,6 +312,8 @@ def xml_propfind_response( elif tag == xmlutils.make_clark("RADICALE:displayname"): # Only for internal use by the web interface displayname = collection.get_meta("D:displayname") + if share and share['Properties'] and share['Properties']["D:displayname"]: + displayname = share['Properties']["D:displayname"] if displayname is not None: element.text = displayname else: @@ -324,6 +326,8 @@ def xml_propfind_response( is404 = True elif tag == xmlutils.make_clark("D:displayname"): displayname = collection.get_meta("D:displayname") + if share and share['Properties'] and share['Properties']["D:displayname"]: + displayname = share['Properties']["D:displayname"] if not displayname and is_leaf: displayname = collection.path if displayname is not None: diff --git a/radicale/sharing/__init__.py b/radicale/sharing/__init__.py index 550f82e2..2bd5df89 100644 --- a/radicale/sharing/__init__.py +++ b/radicale/sharing/__init__.py @@ -111,7 +111,7 @@ PATH_PATTERN: str = "([a-zA-Z0-9/.\\-]+)" # TODO: extend or find better source USER_PATTERN: str = "([a-zA-Z0-9@]+)" # TODO: extend or find better source -OVERLAY_PROPERTIES_WHITELIST: Sequence[str] = ("C:calendar-description", "ICAL:calendar-color", "CR:addressbook-description", "INF:addressbook-color") +OVERLAY_PROPERTIES_WHITELIST: Sequence[str] = ("C:calendar-description", "ICAL:calendar-color", "CR:addressbook-description", "INF:addressbook-color", "D:displayname") def load(configuration: "config.Configuration") -> "BaseSharing":