You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Apr 18, 2026. It is now read-only.
Repository navigation
This repository was archived by the owner on Apr 18, 2026. It is now read-only.
New cross-site cookie not 'SameSite' warning in Chrome #561
I am wondering if anyone else has run into the following warning related to cross-site cookies with the latest version of Chrome. Per the documentation, Chrome version 80 will only deliver cookies set correctly. Is this something that I can fix in my application or something that we need for Google to fix?
Same problem even by adding res.header("Set-Cookie", "HttpOnly;Secure;SameSite=None"); to my server it seems something similar needs to be added on Google's where they are serving https://apis.google.com/js/api.js
Using:
Chrome Version 77.0.3865.90 on MacOS Mojave
Reacted by Rich, Rami Loiferman, Cookinne, Alex, Dinesh, Andres Campuzano, Sandesh Damkondwar, Mahesh Bongani, Sidney Bernardin, 李慧吟 and 3 more
Same problem and also signIn method on auth instance from gapi.auth2.getAuthInstance() has stopped working once I enabled this flag in current version of Chrome (Win10, 77.0.3865.120). Can anything be done about this or is this something that should be fixed on Google side?
Reacted by g2minhle, Jared Donaldson, Alex and Ogheneyoma
Guys, do anyone has any update on this? With chrome 78 signIn suddenly stopped working, I can't really ask users to go into chrome://flags and disable something.
Also, I read the chromestatus links again, and I still think this should be enabled by default only in chrome 80, what happened?
Reacted by Andrew Shannon Brown, khanks and Gabrielle Dias
Will look into this Monday and report a bug to the team when I can reproduce. 🙂 EDIT: Added internal bug b/143761058 and reported to the team. I will update this GitHub issue if there are updates.
Reacted by Grant Kiely, tzatter, Borgstrom ♔, Jswk1, Li-Hsuan Lung, Mathias Gilson, Rich, steveetm, Nathan, Andrew Shannon Brown and 5 more
If you interested in a production site which is affected for sure, go to wish.com and try to login with google. Again, it is working fine if you disable those flags.
@grant said he will report this bug to the team. It might not last long before it's getting fixed...
I found many apps having the same problem, but it concerns only a minority of users using the last version of chrome (cf canary deployment).
After successfully integrating Google Calendar API using gapi library yesterday, I saw my Chrome was out of date.
After updating to v78, the integration stopped working - Sign in popup showed, I could 'sign in' but after the popup closed, nothing happened in the app. No errors though!
3 hours into figuring out what I changed in my codebase, I came across this thread - turns out the 3 flags set to disabled make it work fine again.
Of course, there are warnings about it in the console, but they mention it's due to be changed in FUTURE RELEASE.
I believe this was shipped accidently in v78, however the warnings are not errors because they are yet to be updated as it was meant to ship in later version.
Reacted by Nathan, Mathias Gilson, Gilles Piou, steveetm, Mark, Aymeric and Zehua Tian
As I am still not sure whose fault is this and what is the exact issue I really don't want to rant or anything, but we decided to remove google login at this point. Don't get me wrong, it was planned to do something about the warning, but as this was only a warning to get ready this was totally unexpected. 19 days passed since the original report, you could easily say that forget this method, or something, but this lack of information is totally disappointing.
I was finally able to get this to work by omitting the Domain attribute using Express.js and Node.
It is also noteworthy that I am serving the website on https://127.0.0.1:3000 and I have enabled self-signed certificates so chrome won't throw an SSL error. (e.g. I am developing over https locally)
Wow this is 12 November 2020 and I am facing the same issue with React JS react-google-login library. I am using Microsoft Edge and the warning seems to persist. Here is my code:
Does anyone got some solution for the same? Is it fine to ignore this warning? Will it affect my production website in any way?
Here is the warning message I get:
Because a cookie's SameSite attribute was not set or is invalid, it defaults to SameSite=Lax, which prevents the cookie from being sent in a cross-site request. This behavior protects user data from accidentally leaking to third parties and cross-site request forgery.
Resolve this issue by updating the attributes of the cookie:
Specify SameSite=None and Secure if the cookie should be sent in cross-site requests. This enables third-party use.
Specify SameSite=Strict or SameSite=Lax if the cookie should not be sent in cross-site requests
My understanding is that it's a known issue that some Google Accounts cookies (e.g. SID) generate this warning, but it's safely ignorable. They are emitting the old-style cookies still for backwards compatibility reasons which are too complex to go into here. They also issue newer cookies which have the proper SameSite attributes.
If other cookies that aren't from Google Accounts in your application generate this warning it might be more serious.
For us, the issue got resolved by removing the samesite requirement for
cookies. We never actually needed to set it as we did not have multiple
domains. However when this attribute was introduced, things worked only
when we set it. Now everything seems to work fine in browser.
On Thu, Nov 12, 2020 at 10:52 PM Jonathan Sergent ***@***.***> wrote:
Hi,
My understanding is that it's a known issue that some Google Accounts
cookies (e.g. SID) generate this warning, but it's safely ignorable. They
are emitting the old-style cookies still for backwards compatibility
reasons which are too complex to go into here. They also issue newer
cookies which have the proper SameSite attributes.
If other cookies that aren't from Google Accounts in your application
generate this warning it might be more serious.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#561 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AESI6BAC3O6YMQCWCE7JVHLSPQKVBANCNFSM4I5HDGLA>
.
I ran into this issue a while back when trying to figure out why my cookies wouldn't set in Chrome despite working no Firefox. Here is what I figured out:
If you are running your client-side and server on an http connection, you do not need to set the SameSite or Secure attribute.
The SameSite attribute will default to Lax and cookies will work.
However, if you are running your client-side on an https connection, you need to make sure that your server is also running on an https connection.
In this case, set Secure to true and SameSite to None.
This should work!
名称 域和路径
詹金斯时间戳偏移量 本地主机/
_ga 本地主机/
_gid 本地主机/
OTZ www.google.com/
SID .google.com/
HSID .google.com/
SSID .google.com/
APISID .google.com/
SAPISID .google.com/
小号 .google.com/
优乐 www.google.com/
SIDCC .google.com/
SID .google.com.vn/
HSID .google.com.vn/
SSID .google.com.vn/
APISID .google.com.vn/
SAPISID .google.com.vn/
cppo .facebook.com/
Excuse me, do you know how to prevent these cookies? I'm working on privacy related projects. I don't know how to prevent cookie injection? Maybe you have some information or something
Activity
[-]Cross-site cookie not 'SameSite' warning[/-][+]New cross-site cookie not 'SameSite' warning in Chrome[/+]paulzmuda commentedon Oct 14, 2019
Same problem even by adding
res.header("Set-Cookie", "HttpOnly;Secure;SameSite=None");to my server it seems something similar needs to be added on Google's where they are servinghttps://apis.google.com/js/api.jsUsing:
Chrome Version 77.0.3865.90 on MacOS Mojave
Jswk1 commentedon Oct 16, 2019
Same problem and also
signInmethod on auth instance fromgapi.auth2.getAuthInstance()has stopped working once I enabled this flag in current version of Chrome (Win10, 77.0.3865.120). Can anything be done about this or is this something that should be fixed onGoogleside?steveetm commentedon Oct 25, 2019
Guys, do anyone has any update on this? With chrome 78
signInsuddenly stopped working, I can't really ask users to go into chrome://flags and disable something.Also, I read the chromestatus links again, and I still think this should be enabled by default only in chrome 80, what happened?
borgstrom commentedon Oct 26, 2019
cc @grant @bochunz
grant commentedon Oct 26, 2019
Will look into this Monday and report a bug to the team when I can reproduce. 🙂
EDIT: Added internal bug b/143761058 and reported to the team. I will update this GitHub issue if there are updates.
steveetm commentedon Oct 28, 2019
If you interested in a production site which is affected for sure, go to wish.com and try to login with google. Again, it is working fine if you disable those flags.
steveetm commentedon Oct 28, 2019
Sorry for being hasty there, but I can't believe it is affecting only us. Any update?
nthglsn commentedon Oct 28, 2019
@grant said he will report this bug to the team. It might not last long before it's getting fixed...
I found many apps having the same problem, but it concerns only a minority of users using the last version of chrome (cf canary deployment).
MathiasGilson commentedon Oct 30, 2019
@grant when disabling the following flags on chrome the login works
steveetm commentedon Oct 30, 2019
For me it was enough to disable 'SameSite by default cookies'.
Do you guys know if this is a bug in this lib, or Chrome 78 accidentally enabled this flag 2 releases earlier?
WJakub commentedon Nov 1, 2019
After successfully integrating Google Calendar API using gapi library yesterday, I saw my Chrome was out of date.
After updating to v78, the integration stopped working - Sign in popup showed, I could 'sign in' but after the popup closed, nothing happened in the app. No errors though!
3 hours into figuring out what I changed in my codebase, I came across this thread - turns out the 3 flags set to disabled make it work fine again.
Of course, there are warnings about it in the console, but they mention it's due to be changed in FUTURE RELEASE.
I believe this was shipped accidently in v78, however the warnings are not errors because they are yet to be updated as it was meant to ship in later version.
MathiasGilson commentedon Nov 2, 2019
@grant did you have time to look at it?
Your help would be really appreciated on this one 🤗
steveetm commentedon Nov 4, 2019
As I am still not sure whose fault is this and what is the exact issue I really don't want to rant or anything, but we decided to remove google login at this point. Don't get me wrong, it was planned to do something about the warning, but as this was only a warning to get ready this was totally unexpected. 19 days passed since the original report, you could easily say that forget this method, or something, but this lack of information is totally disappointing.
grant commentedon Nov 4, 2019
I assure you this is being looked at. There were updates today internally.
I updated that comment 3 days ago before the weekend. I've increased the priority of the internal issue.
60 remaining items
ChannelJuanNews commentedon Oct 26, 2020
I was finally able to get this to work by omitting the
Domainattribute using Express.js and Node.It is also noteworthy that I am serving the website on
https://127.0.0.1:3000and I have enabled self-signed certificates so chrome won't throw an SSL error. (e.g. I am developing over https locally)This is the response Header for the
Set-CookieAttributeSet-Cookie: token=somestring; Max-Age=604; Path=/endpoint/of/request; Expires=Mon, 26 Oct 2020 18:29:32 GMT; HttpOnly; Secure; SameSite=NoneShout out to Lily Chen @ chromium for helping me solve this issue. I really appreciate it.
sedhha commentedon Nov 12, 2020
Wow this is 12 November 2020 and I am facing the same issue with React JS
react-google-loginlibrary. I am using Microsoft Edge and the warning seems to persist. Here is my code:Does anyone got some solution for the same? Is it fine to ignore this warning? Will it affect my production website in any way?
Here is the warning message I get:
sergentj commentedon Nov 12, 2020
Hi,
My understanding is that it's a known issue that some Google Accounts cookies (e.g.
SID) generate this warning, but it's safely ignorable. They are emitting the old-style cookies still for backwards compatibility reasons which are too complex to go into here. They also issue newer cookies which have the proper SameSite attributes.If other cookies that aren't from Google Accounts in your application generate this warning it might be more serious.
Nagendracv commentedon Nov 13, 2020
akdu12 commentedon Nov 26, 2020
@sedhha did you solve it? I have the same issue and apparently it blocks sign in from working
sedhha commentedon Nov 28, 2020
@akdu12 unfortunately no. For now, I am just ignoring it... as everyone said but not sure what will be it's impact.
bangnguyendev commentedon Feb 19, 2021
MattG561 commentedon Jun 10, 2021
Any update on this? It's been almost 2 years..
clemsontiger commentedon Jun 16, 2021
Same here, we still use google translate and it's still showing up for the google translate related cookies....
Julian-Silvestri commentedon Jul 9, 2021
bump ....
Why this closed....
bump !
khanks commentedon Jul 9, 2021
Because if you haven't figured it out by now, you're not going to figure it out at all.
Julian-Silvestri commentedon Jul 9, 2021
lolz k thanks
Mahdiyeh commentedon Aug 11, 2021
May I ask what does it mean? Is it a question? an error? Or a response?
SyedHusaini commentedon Aug 20, 2021
I ran into this issue a while back when trying to figure out why my cookies wouldn't set in Chrome despite working no Firefox. Here is what I figured out:
If you are running your client-side and server on an http connection, you do not need to set the SameSite or Secure attribute.
The SameSite attribute will default to Lax and cookies will work.
However, if you are running your client-side on an https connection, you need to make sure that your server is also running on an https connection.
In this case, set Secure to true and SameSite to None.
This should work!
yangfan-coder commentedon Jan 25, 2022