I've seen the other posts(Solspace freeform "form expired" under EE 2.8) about this same issue. but they didn't really solve the issue. I really have to get this working as this form has dragged on a while with issues. I have a multipage form and I get the error sometimes after submitting the first page. Other posts say to disable the CSRF protection using the config.php, but I've been told this isn't good for security. I can post template code, but I don't know if my setup even matters as other people have the same issue. Please let me know if you need any more information, thanks!

EE v2.9.3

Freeform Pro v4.2.2

  • By default CSRF tokens expire with the user session (which by default is 2 hours for front-end sessions or one hour for back-end sessions). So if you've set a really short cookie session, or you clear your cookies, or if you login/logout of the EE admin in a separate window while you're filling out the form, your token will be invalidated. Can you confirm that none of these things are happening? Commented Nov 20, 2015 at 15:20
  • Derek Hogue is correct, the exception being logged-in members, whose CSRF expires with their active session rather than the shorter time-base used with guests, whose CSRF uses cookie storage. So for guests, if they leave the page open across that two hour threshold, they would get that error. Commented Nov 20, 2015 at 16:28
  • I just did a test, the form was working fine, then I let it sit on the page for 2 hours and tried again and got the expired warning. All of the form users will be guests and they probably won't be sitting on the page for an extended period of time so I'm hoping this won't end up being an issue after all. My client must have been sitting on the page, I'll have to ask him. Thanks for giving me a metric to test against. Commented Nov 20, 2015 at 20:19


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.