From cb413bae49e7a349055b018f342ed0b06a410a13 Mon Sep 17 00:00:00 2001 From: ed Date: Wed, 19 Feb 2025 22:07:26 +0000 Subject: [PATCH] webdav: a healthy dash of paranoia there's probably at least one client sending `Overwrite: False` instead of the spec-correct `Overwrite: F` --- copyparty/httpcli.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/copyparty/httpcli.py b/copyparty/httpcli.py index c8209717..5f3dec08 100644 --- a/copyparty/httpcli.py +++ b/copyparty/httpcli.py @@ -1811,7 +1811,8 @@ class HttpCli(object): dst = unquotep(dst) # overwrite=True is default; rfc4918 9.8.4 - overwrite = self.headers.get("overwrite", "").lower() != "f" + zs = self.headers.get("overwrite", "").lower() + overwrite = zs not in ["f", "false"] try: fun = self._cp if self.mode == "COPY" else self._mv