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

fix(webkit): make cookie SameSite=Lax by default #31012

Closed
wants to merge 3 commits into from

Conversation

yury-s
Copy link
Member

@yury-s yury-s commented May 24, 2024

“Prevent cross-site tracking” feature is on by default in Safari. It prevents SameSite=None cookie behavior, making such cookies Lax. With this PR the following behavior changes:

  • The following cookies become SameSite=Lax when added via addCookies call:

    • SameSite is not specified
    • SameSite=None is specified
  • Cookies added via document.cookies='foo=bar' are now reported as Lax.

Reference #30305
Reference https://github.com/microsoft/playwright-browsers/issues/795

@yury-s
Copy link
Member Author

yury-s commented May 24, 2024

This is based on mxschmitt@0b6e317

This comment has been minimized.

Copy link
Contributor

Test results for "tests 1"

9 failed
❌ [playwright-test] › playwright.ct-react.spec.ts:253:5 › should pass "key" attribute from JSX in variable
❌ [webkit-library] › library/browsercontext-cookies.spec.ts:24:3 › should get a cookie @smoke
❌ [webkit-library] › library/browsercontext-cookies.spec.ts:43:3 › should get a non-session cookie
❌ [webkit-library] › library/browsercontext-cookies.spec.ts:112:3 › should get multiple cookies
❌ [webkit-library] › library/browsercontext-cookies.spec.ts:353:3 › should support requestStorageAccess
❌ [webkit-library] › library/browsercontext-fetch.spec.ts:1205:3 › should support set-cookie with SameSite and without Secure attribute over HTTP
❌ [webkit-library] › library/browsercontext-route.spec.ts:112:3 › should support Set-Cookie header
❌ [webkit-library] › library/browsercontext-route.spec.ts:155:3 › should use Set-Cookie header in future requests
❌ [webkit-library] › library/defaultbrowsercontext-1.spec.ts:22:3 › context.cookies() should work @smoke

1 flaky ⚠️ [playwright-test] › ui-mode-test-screencast.spec.ts:21:5 › should show screenshots

27047 passed, 609 skipped
✔️✔️✔️

Merge workflow run.

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

Successfully merging this pull request may close these issues.

3 participants