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

cy.setCookie incorrectly sets a non hostOnly cookie by default #363

Closed
brian-mann opened this issue Dec 27, 2016 · 6 comments · Fixed by #24692
Closed

cy.setCookie incorrectly sets a non hostOnly cookie by default #363

brian-mann opened this issue Dec 27, 2016 · 6 comments · Fixed by #24692

Comments

@brian-mann
Copy link
Member

We are incorrectly setting non hostOnly cookies to the superdomain of the remote origin.

This means that this cookie would be sent on all subdomains.

This is wrong, by default it needs to set a hostOnly cookie to the remote origin.

@brian-mann brian-mann self-assigned this Dec 27, 2016
@jennifer-shehane jennifer-shehane added stage: ready for work The issue is reproducible and in scope topic: cookies 🍪 labels Feb 1, 2019
@flotwig
Copy link
Contributor

flotwig commented Jan 16, 2020

@brian-mann this would be a breaking change if updated today, correct?

@brian-mann
Copy link
Member Author

Not if its been a bug since day 1

@flotwig
Copy link
Contributor

flotwig commented Jan 16, 2020

Which is why I think it's breaking, fixing it would change the behavior of cy.setCookie since day 1 :P

I need to verify that this change didn't accidentally get made when we switched to using CDP for cookies.

@flotwig flotwig self-assigned this Jan 16, 2020
@jennifer-shehane jennifer-shehane added the type: breaking change Requires a new major release version label Nov 16, 2020
@AtofStryker
Copy link
Contributor

fixed by #24692

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Nov 23, 2022

The code for this is done in cypress-io/cypress#24692, but has yet to be released.
We'll update this issue and reference the changelog when it's released.

@cypress-bot
Copy link
Contributor

cypress-bot bot commented Dec 6, 2022

Released in 12.0.0.

This comment thread has been locked. If you are still experiencing this issue after upgrading to
Cypress v12.0.0, please open a new issue.

@cypress-bot cypress-bot bot locked as resolved and limited conversation to collaborators Dec 6, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants