public inbox for pve-devel@lists.proxmox.com
 help / color / mirror / Atom feed
* [pve-devel] [PATCH widget-toolkit] Utils: clear cookies with secure flag set
@ 2022-03-18 10:00 Dominik Csapak
  2022-03-18 15:29 ` [pve-devel] applied: " Thomas Lamprecht
  0 siblings, 1 reply; 2+ messages in thread
From: Dominik Csapak @ 2022-03-18 10:00 UTC (permalink / raw)
  To: pve-devel

otherwise firefox complains with a deprecation warning that the secureflag
is not set but SameSite to 'None'. Since we cannot know how firefox will
behave once that behaviour is no longer supported, add the secure flag
now.

we have to use the 'set' api of ExtJs to do that reliably

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
---
 src/Utils.js | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/Utils.js b/src/Utils.js
index 6781e44..52cc626 100644
--- a/src/Utils.js
+++ b/src/Utils.js
@@ -306,7 +306,7 @@ utilities: {
 	if (Proxmox.LoggedOut) {
 	    return;
 	}
-	Ext.util.Cookies.clear(Proxmox.Setup.auth_cookie_name);
+	Ext.util.Cookies.set(Proxmox.Setup.auth_cookie_name, "", new Date(0), null, null, true);
 	window.localStorage.removeItem("ProxmoxUser");
     },
 
-- 
2.30.2





^ permalink raw reply	[flat|nested] 2+ messages in thread

* [pve-devel] applied: [PATCH widget-toolkit] Utils: clear cookies with secure flag set
  2022-03-18 10:00 [pve-devel] [PATCH widget-toolkit] Utils: clear cookies with secure flag set Dominik Csapak
@ 2022-03-18 15:29 ` Thomas Lamprecht
  0 siblings, 0 replies; 2+ messages in thread
From: Thomas Lamprecht @ 2022-03-18 15:29 UTC (permalink / raw)
  To: Proxmox VE development discussion, Dominik Csapak

On 18/03/2022 11:00, Dominik Csapak wrote:
> otherwise firefox complains with a deprecation warning that the secureflag
> is not set but SameSite to 'None'. Since we cannot know how firefox will
> behave once that behaviour is no longer supported, add the secure flag
> now.
> 
> we have to use the 'set' api of ExtJs to do that reliably
> 
> Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
> ---
>  src/Utils.js | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
>

applied, thanks! Added a comment in a follow-up though.




^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2022-03-18 15:30 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-03-18 10:00 [pve-devel] [PATCH widget-toolkit] Utils: clear cookies with secure flag set Dominik Csapak
2022-03-18 15:29 ` [pve-devel] applied: " Thomas Lamprecht

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
Service provided by Proxmox Server Solutions GmbH | Privacy | Legal