Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

HttpOnly cookie #7

Open
besnikh opened this issue Sep 10, 2018 · 0 comments
Open

HttpOnly cookie #7

besnikh opened this issue Sep 10, 2018 · 0 comments

Comments

@besnikh
Copy link

besnikh commented Sep 10, 2018

I used a lot of this repo to do ssr auth on my side, especially the req thing was very usefull.

I am little confused about the HttpOnly flag, protecting agains XSS .. and you are not using here but also that is referenced on Firebase Auth.

Am I wrong here or should we use something else to "protect" cookie ?

I tried to do something like this but It's not working:

auth.addAuthTokenListener(function (idToken) {
   document.cookie = '__session=' + idToken + ';max-age=' + (idToken ? 604800 : 0) + ';HttpOnly'
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant