diff --git a/files/routes/allroutes.py b/files/routes/allroutes.py index 8184ad4b6..4d09cda16 100644 --- a/files/routes/allroutes.py +++ b/files/routes/allroutes.py @@ -47,7 +47,8 @@ def after_request(response): if response.status_code < 400: if CLOUDFLARE_AVAILABLE and CLOUDFLARE_COOKIE_VALUE and getattr(g, 'desires_auth', False): logged_in = bool(getattr(g, 'v', None)) - response.set_cookie("lo", CLOUDFLARE_COOKIE_VALUE if logged_in else '', max_age=60*60*24*365 if logged_in else 1) + response.set_cookie("lo", CLOUDFLARE_COOKIE_VALUE if logged_in else '', + max_age=60*60*24*365 if logged_in else 1, samesite="Lax") if getattr(g, 'db', None): g.db.commit() g.db.close()