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

Use a nonce for cookie regeneration #627

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

mkawalec
Copy link

This implements #425 by setting up an extra nonce cookie when regenerate is set to true. That nonce is validated against the previous value and refreshed on each request. This adds an additional write per request to the cookie store, regardless of if the state was modified or not.

Also fixes the getCookie method in tests to look at all the cookies set in a response, not just the first one.

test/session.js Outdated Show resolved Hide resolved
test/session.js Outdated Show resolved Hide resolved
@mkawalec
Copy link
Author

mkawalec commented Mar 8, 2019

@dougwilson @brian-learningpool rereview please

@mihir83in
Copy link

Hi Guys any news on this ?

@brian-learningpool
Copy link

@mkawalec, apologies for the delay in this, I completely missed the notification that you had updated the PR. Your changes look good but there are conflicts in a couple of files.

Also, I'm just a long-time fan and user of express-session, I don't have contributor access so I'm not sure what my approval is worth.

@mkawalec
Copy link
Author

Will rebase soon, hopefully we'll get this across the finish line in 2019 :D

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants