httpOnly cookies are shown in browser console

19 Views Asked by At

My express app is running on localhost:4000 and is setting two cookies like this:

res.cookie('accessToken',token, { maxAge: 3600000, httpOnly: true, secure: false,Path: './',SameSite: 'None' });
res.cookie('refreshToken',_token, { maxAge: 86400000, httpOnly: true, secure:false,Path: './',SameSite: 'None' });

secure is false since I am on localhost but httpOnly is set to true.

Looking at network tab on localhost:80 I expected not to have any cookie displayed but I can see the cookies displayed and with the httpOnly flag set to true. What am I doing wrong?

enter image description here

0

There are 0 best solutions below