Symfony 2 "Your session has timed out or you have disabled cookies" Symfony 2 "Your session has timed out or you have disabled cookies" symfony symfony

Symfony 2 "Your session has timed out or you have disabled cookies"


I ultimately found the answer here:Symfony authentication - can't get past login page in production (The answer by pleerock)

But wanted to link the error message in my subject line with this solution below:

security:    firewalls:        main:            form_login:                require_previous_session: false

This fixed the issue for browsers which hadn't been logged in prior to the problem.

For my browser which had already been logged in, I had to manually delete the session cookie to get things working again.


I think Adi's answer is not a solution, just work around.

i did realise

in config.yml there is cookie_domain parameter;

session:    save_path: ~    cookie_domain: %cookie_domain%

if you use a custom domain like test.myapp you should set here the same. When these both do not match this problem occurs.

It should appear as below;

cookie_domain: 'test.myapp'your actual domain: test.myapp

i hope this helps you.