I know my issue is not because of Laravel but most likely the php configuration (sessions), but I am not sure what to check. I was running this particular project on a
homestead and it was fine. Now after I submit a form (it's a steps controller,
post form -> go to step 2 etc.) and refresh the page my csrf token is invalid.
I thought it was because of session lifetime and such or generation of new token, but no .. the token is the same, but I still get
TokenMismatchException after I refresh the page.
The environment is pretty much the same as the homestead (nginx (latest), php(5.6, I don't know what homestead had) ). The logins work fine, I stay logged in while browsing, but when I go through the steps this happens ..
Problem & Solution:
As per comments bellow where I forgot to update, I found out the problem was actually the fact, that the dev server was forced through cloudflare, but the base url in Laravel was left at
http://... - I just added to
and it wasn't doing the verification error.