Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I setup a local environment to work with the latest SameSite cookie change to Chrome?

I'm building an app with ReactJS and with the latest change to Chrome we're unable to get the cookie back as it's provided by a Central Authentication Service. Granted, in prod it'll have the same domain as the JS app, but for now it is breaking the app locally. I know about SameSite=None; Secure but that still needs the third party app (the React app) to access using a secure connection. To me going through those changes locally is overkill.

Is there no other way?

Edit: I have also tried mapping to a domain equal to the auth server in the hosts file but it didn't work.

like image 958
Daniel Arechiga Avatar asked Nov 07 '22 09:11

Daniel Arechiga


1 Answers

I'm passing for the same difficulty. According to what I read/researched there is nothing that can be done. Who should do this is whoever provides the service/cookie.

A temporary solution is to disable the flags "SameSite by default cookies" and "Cookies without SameSite must be secure", to do this go to: chrome://flags.

More info: https://blog.chromium.org/2019/10/developers-get-ready-for-new.html

like image 104
Patrick Avatar answered Nov 14 '22 23:11

Patrick