mirror of
https://github.com/Kozea/Radicale.git
synced 2025-06-26 16:45:52 +00:00
Error message if path not starting with prefix
Before the program crashed implicitly
This commit is contained in:
parent
780cecc0f2
commit
ed44830447
1 changed files with 3 additions and 1 deletions
|
@ -265,7 +265,9 @@ class Application(object):
|
||||||
# Request path not starting with base_prefix, not allowed
|
# Request path not starting with base_prefix, not allowed
|
||||||
log.LOGGER.debug(
|
log.LOGGER.debug(
|
||||||
"Path not starting with prefix: %s", environ["PATH_INFO"])
|
"Path not starting with prefix: %s", environ["PATH_INFO"])
|
||||||
environ["PATH_INFO"] = None
|
status, headers, _ = NOT_ALLOWED
|
||||||
|
start_response(status, list(headers.items()))
|
||||||
|
return []
|
||||||
|
|
||||||
# Sanitize request URI
|
# Sanitize request URI
|
||||||
environ["PATH_INFO"] = self.sanitize_uri(environ["PATH_INFO"])
|
environ["PATH_INFO"] = self.sanitize_uri(environ["PATH_INFO"])
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue