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

Default cookie expiration way too long #243

Closed
allen-cook opened this issue May 8, 2019 · 2 comments
Closed

Default cookie expiration way too long #243

allen-cook opened this issue May 8, 2019 · 2 comments

Comments

@allen-cook
Copy link
Contributor

When you set
JWT_SESSION_COOKIE = False to enable permanent cookies, the expiration date set by default is way too long and the browser will sometimes treat it as invalid and set the cookie as a session cookie anyway.

Expiration dates on permanent cookies typically need to be before 2038 since it's specified in a UNIX epoch format.

@vimalloc
Copy link
Owner

vimalloc commented May 8, 2019

I was not aware of that, great find! Do you want to put together a pull request to get that fixed up? Should be as simple as changing the value here (https://github.com/vimalloc/flask-jwt-extended/blob/master/flask_jwt_extended/config.py#L280) then adding/updating a unit test for the config value.

@vimalloc
Copy link
Owner

Released in version 3.18.2. Cheers!

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

2 participants