Users cannot login - CSRF cookie not set

There is a new google chrome update that is rejecting cookies with the following message:

This Set-Cookie was blocked because it had the “SameSite=None” attribute but did not have the “Secure” attribute, which is required in order to use “SameSite=None”.

You can see further information here:

Pull request were referenced there.

In the meanwhile I fixed the problem adding:


In env/apps/openedx/settings/lms/ and env/apps/openedx/settings/cms/


Hi @juansele,

Thank you so much for the tip. Should I be able to make a similar change to We’re using our forked version of edx-platform. I’m just wondering what exact env file to use. Is it or other file?

Hi @juansele

Thanks for the hint. I just want to make sure that the lines to add are:

# django-session-cookie middleware

Isn’t lax should in double quotes like this “Lax”?
Did you have to run to rebuild the docker image? or just run “tutor local quickstart”?


Hello @nachham,
editing those files is not the tutor way to go. So I’ve created a plugin so the change persist between rebuilds.

To install/use it please follow:

tutor plugins install
tutor plugins enable tempchromecsrffix
tutor config save
tutor local reboot

Just for the sake of clarity, in the case you want to make the edits manually:

  • It is a python file so you can use either single or double quotes.
  • We are editing files within a “docker volume”, so all you need to do is tutor local restart cms. However those files are dynamically generated and overwritten when you do a tutor config save (which tutor local quickstart performs).
1 Like

Hello @tuananh-pham,
I am not sure which one you should edit for a non-tutor installation. In the forum I linked they do edit indeed.

Thanks @juansele

Hi. We are using tutor k8s deployment, with custom edx-platform fork. Should we change the file?

I suggest you use the plugin. Let me know if it works

We got it fixed by changing in edx-platform repo’s cms/envs/


Hi! I’m jumping in this conversation a little late, but I wonder if the default Tutor production settings should be modified.

Can someone please clarify:

  1. Which version of Tutor are you running?
  2. How to reproduce the issue?
  3. Are you quite sure that setting DCS_SESSION_COOKIE_SAMESITE = 'Lax' is the right thing to do? The name of this value (“lax”) would imply that this is meant only for development, not production.

Hey @regis

I’m facing the same issue in Chrome, if I open the dev tools I see the next error

Btw, if I’m using Firefox the issue doesn’t happen and I’m able to login

@bryancr89 please explain how to reproduce the issue.

Hi @regis,

  1. I am running 10.1.0
  2. Run tutor on “production”, try to log in using updated google chrome
    chrome will block cookies.
  3. Maybe setting the “Secure” attribute is a better solution.

Thanks for the report everyone. This will be fixed in the next release of Tutor (v10.2.0). The “right” fix consists of adding the following entries to the LMS production settings when HTTPS is enabled:


And when HTTPS is disabled:


These settings will be included in v10.2.0, which should be released today.