diff --git a/radicale/__init__.py b/radicale/__init__.py index 4bfd1deb3..b0ffc385d 100644 --- a/radicale/__init__.py +++ b/radicale/__init__.py @@ -364,6 +364,9 @@ def response(status, headers=(), answer=None): environ["PATH_INFO"] = storage.sanitize_path(environ["PATH_INFO"]) self.logger.debug("Sanitized path: %s", environ["PATH_INFO"]) path = environ["PATH_INFO"] + if base_prefix and path.startswith(base_prefix): + path = path[len(base_prefix):] + self.logger.debug("Stripped script name from path: %s", path) # Get function corresponding to method function = getattr(self, "do_%s" % environ["REQUEST_METHOD"].upper())