From c71128fd7222287b9437486a0e391bff079c3955 Mon Sep 17 00:00:00 2001 From: ed Date: Wed, 3 Sep 2025 19:50:54 +0000 Subject: [PATCH] ignore cppws on plaintext; cppws, if set from https context, cannot be cleared by plaintext this could lead to confusing login/logout behavior --- copyparty/httpcli.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/copyparty/httpcli.py b/copyparty/httpcli.py index 171791a7..a379f655 100644 --- a/copyparty/httpcli.py +++ b/copyparty/httpcli.py @@ -567,7 +567,7 @@ class HttpCli(object): return False zsll = [x.split("=", 1) for x in zso.split(";") if "=" in x] cookies = {k.strip(): unescape_cookie(zs) for k, zs in zsll} - cookie_pw = cookies.get("cppws") or cookies.get("cppwd") or "" + cookie_pw = cookies.get("cppws" if self.is_https else "cppwd") or "" if "b" in cookies and "b" not in uparam: uparam["b"] = cookies["b"] if len(cookies) > self.args.cookie_nmax: