I'm in charge of multiple Drupal 8 website and with some of them, the hidden field form_token is non-existent when I'm using the website anonymously.

Everything works fine when I'm logged in.

I'm sure everything was working before the quarantine but I didn't check before updating to 8.8.6

I tried deleting the custom twig templates of the webform and I checked my theme.theme

webform version is 8.x-5.13 for some and 8.x-5.16 for others.

  • In D7 at least, tokens did not work consistently between anonymous - the initial token wouldn't match the new generated token upon submission. This may be why it doesn't exist for anonymous users. – Jaypan Jun 5 '20 at 14:59

The problem comes from the antibot module.

For some reason that I don't know, when I am not logged in, the module considers that I do not have javascrip enabled and overrides the form_token field which is required to submit the form.

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.