1

First of all the control panel login is unstyled, and I'm getting Bad Request Unable to verify your data submission when trying to login to the control panel. I can login using a form on the front end, but then I find the CP is still unstyled. Using console I can see the cpresources files cannot be found by the browser - but I've checked they are there, and have file permissions set.

Any ideas???

1
  • In my case I had a module uploading large files to s3, it got fixed after tweaks on upload_max_filesize, post_max_size and max_execution_time. One can get sidetracked by the CSRF error, but it was actually execution timeout.
    – Leoncio
    Aug 19 at 0:57
3

There isn't really enough information here to give a full answer, but 'Bad Request Unable to verify your data submission' means that Craft is not getting supplied the correct CSRF token.

To confirm, try turning off CSRF protection in your config: https://craftcms.com/docs/3.x/config/config-settings.html#enablecsrfprotection

1
  • I don't quite understand what is going on, but I turned off CSRF protection, then changed the cpresources to 774 all is OK. I then removed CSRF protection false from the config and still OK. (So marking your answer correct for that reason!)
    – Andrew
    Sep 30 '20 at 7:18
1

I replaced cpresources from the dev environment with the original backup, and got going again. The reason seemed to be permissions - cpresources worked with 705, but not with 774.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.