aymhce / diasporadocker_ynh

GNU General Public License v3.0
1 stars 2 forks source link

Invalid CSRF Token #10

Closed lesamarien closed 6 years ago

lesamarien commented 6 years ago

Hello If I want to use Chrome or my smartphone, I can not sign in or create an account. I have this error every time: the CSRF token is invalid. The site only works with Firefox (ubuntu and Windows) and IE (windows) I looked on the web, but I can not find a solution.

Bonjour Si je veux utiliser Chrome ou mon smartphone, je n'arrive pas à me connecter ni à créer de compte. J'ai cette erreur à chaque fois : le jeton CSRF est invalide. Le site ne fonctionne qu'avec Firefox (ubuntu et Windows) et IE (windows) J'ai regardé sur le web, mais je ne trouve pas de solution.

lesamarien commented 6 years ago

Hello

I found the solution to my problem. If it helps, here is what worked for me: it was enough to add the following lines in the file nginx diasporadocker.conf

proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; proxy_set_header X-Forwarded-Proto $scheme;