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: Chrome rejects refresh_token cookie in cross-origin requests due to missing SameSite attribute. #103

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lxbdr
Copy link
Contributor

@lxbdr lxbdr commented Apr 24, 2023

Chrome prohibits the refresh_token cookie from being set from cross-origin requests because it is missing the samesite attribute.

Things to consider:

  • This syntax requires a minimum PHP version of 7.3. Do we need a version check or workaround here to support a lower version?
  • The default for samesite would be Lax maybe this could even be set to Strict as the refresh_token is probably only used on subsequent requests in a first-party context when not cross-origin.

@sun sun self-requested a review April 5, 2024 22:20
@sun sun changed the title add samesite attribute to refresh_token cookie fix: Chrome rejects refresh_token cookie in cross-origin requests due to missing SameSite attribute. Oct 2, 2024
@sun sun added the bug Something isn't working label Oct 2, 2024
@sun
Copy link
Collaborator

sun commented Oct 2, 2024

Sorry for not getting to this earlier. 😬 Your proposed change looks good to me.

We could move forward with it – although Google is now stating that we should implement other/additional measures in the meantime:

Do we want to investigate that here or in a separate issue/PR?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants