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 name doesn't satisfy RFC6265 #16

Closed
guersam opened this issue Jul 2, 2014 · 7 comments
Closed

Default cookie name doesn't satisfy RFC6265 #16

guersam opened this issue Jul 2, 2014 · 7 comments
Assignees
Labels

Comments

@guersam
Copy link

guersam commented Jul 2, 2014

The default cookie name express:sess contains :, which is not a valid token character in accordance with RFC6265 and RFC2616. Although most web browsers and servers allow this, it causes problems in some more strict environment such as spray.

Would you consider remaining it? If so, should we take backward compatibility into account?

p.s. I posted the same issue as koajs/session#28.

@dougwilson dougwilson added the bug label Jul 2, 2014
@Fishrock123
Copy link
Contributor

This breaks anyone who is naively using any hard-coded references to the default cookie name.

For now, just use the name option.

@dougwilson
Copy link
Contributor

This breaks anyone who is naively using any hard-coded references to the default cookie name.

Exactly. We should probably change it, but cannot for some time.

@dougwilson
Copy link
Contributor

Perhaps we should just not even have this be a default? I think that would be the better option to make people choose their own cookie names, since that is basically an integral part of cookies.

@Fishrock123
Copy link
Contributor

Perhaps we should just not even have this be a default?

Yeah, that might be a good idea.
We should probably also error on RFC-invalid cookie names.

@dougwilson
Copy link
Contributor

We should probably also error on RFC-invalid cookie names.

Yea. I looked at the RFC and it says the cookie name should be a token (which cannot have things like :).

@anextro
Copy link

anextro commented Apr 14, 2015

Has this problem been solved.?

@dougwilson
Copy link
Contributor

@anextro no, not until the next major release. You can always just use a different cookie name from the default for your app in the meantime.

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

No branches or pull requests

4 participants