Cookies on localhost not being set... what to do?

92 views Asked by At

I have a frontend running on http://localhost:5173 and a backend running on http://localhost:3000. I just can't test cookies sent by the backend anymore... the POST response looks like this:

Access-Control-Allow-Origin: http://localhost:5173
Vary: Origin
Access-Control-Allow-Credentials: true
Content-Type: application/json; charset=utf-8
Content-Length: 118
ETag: W/"76-RnnHeJL+YLKFl67NESlMHiQ6x/0"
Set-Cookie: connect.sid=MYSECRETCOOKIE_123455; Path=/; Expires=Mon, 19 Feb 2024 00:50:59 GMT; HttpOnly; SameSite=None

I know this won't work on Chrome, because SameSite=None and Secure!=true but it used to be that on Firefox I could disable the Cookies without SameSite must be secure option.

However, on Firefox Mac build 122.0.1, this is still not setting the cookie.

Is there any alternative on how to test cookies with different URLs on local deployments?

0

There are 0 answers