auth0/auth0-react

Can not get the access token on Firefox browser

giangbv1984 opened this issue · 6 comments

Checklist

Description

Unable to get access token due to cookie policy on Firefox browser.
Error message:
Some cookies are incorrectly using the recommended attribute “SameSite“ 5
Cookie “auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.organization_hint” does not have the appropriate “SameSite” attribute value. Going forward, cookies without the “SameSite” attribute or with an invalid value will be considered “Lax”. This means that cookies will no longer be sent in a third-party context. If your application depends on this cookie being available in such contexts, please add the “SameSite=None” attribute to it. To know more about the “SameSite” attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite @auth0_auth0-react.js:789:22
Cookie “auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.organization_hint” does not have the appropriate “SameSite” attribute value. Going forward, cookies without the “SameSite” attribute or with an invalid value will be considered “Lax”. This means that cookies will no longer be sent in a third-party context. If your application depends on this cookie being available in such contexts, please add the “SameSite=None” attribute to it. To know more about the “SameSite” attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite @auth0_auth0-react.js:789:22
Cookie “_legacy_auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.organization_hint” does not have the appropriate “SameSite” attribute value. Going forward, cookies without the “SameSite” attribute or with an invalid value will be considered “Lax”. This means that cookies will no longer be sent in a third-party context. If your application depends on this cookie being available in such contexts, please add the “SameSite=None” attribute to it. To know more about the “SameSite” attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite @auth0_auth0-react.js:789:22
Cookie “auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.is.authenticated” does not have the appropriate “SameSite” attribute value. Going forward, cookies without the “SameSite” attribute or with an invalid value will be considered “Lax”. This means that cookies will no longer be sent in a third-party context. If your application depends on this cookie being available in such contexts, please add the “SameSite=None” attribute to it. To know more about the “SameSite” attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite 2 @auth0_auth0-react.js:789:22
Cookie “_legacy_auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.is.authenticated” does not have an appropriate “SameSite” attribute value. Going forward, cookies without the “SameSite” attribute or with an invalid value will be considered “Lax”. This means that cookies will no longer be sent in a third-party context. If your application depends on this cookie being available in such contexts, please add the “SameSite=None” attribute to it. To know more about the “SameSite” attribute, read https://developer.mozilla.org/docs/Web/HTTP/Headers/Set-Cookie/SameSite

Reproduction

Unable to get access token due to cookie policy on Firefox browser.
image

Additional context

No response

auth0-react version

2.1.0

React version

17.02

Which browsers have you tested in?

Firefox

I dont see how that could cause the issue you mention. The cookie “auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.organization_hint” is ment for local access only, and should not be sent to a server. So the warning should not cause issues with the functionality.

I assume something else is going on. Do you have third party cookies blocked?

I dont see how that could cause the issue you mention. The cookie “auth0.qZh0xCOCcama7KQbjk7ZnioQerH8uRDq.organization_hint” is ment for local access only, and should not be sent to a server. So the warning should not cause issues with the functionality.

I assume something else is going on. Do you have third party cookies blocked?

I do not use a cookie blocker. However, this error only appears on Firefox

On Chrome, I still see the auth0 cookie being added to memory, however on Firefox it is not. So getting the access token failed.

Please provide a reproduction so we can look into this, as the information provides is insufficient for us to act accordingly. Once we have a reproduction we can look into this.

You can use https://github.com/auth0-samples/auth0-react-samples to help reproduce this, ensure to provide us with either a forked version that reproduces the issue, or clear reproduction steps on how to reproduce it in that sample.

Please provide a reproduction so we can look into this, as the information provides is insufficient for us to act accordingly. Once we have a reproduction we can look into this.

You can use https://github.com/auth0-samples/auth0-react-samples to help reproduce this, ensure to provide us with either a forked version that reproduces the issue, or clear reproduction steps on how to reproduce it in that sample.

Okay, will soon.

Closing, can reopen if you have a reproduction.