Error message

You need to log in or create an account to access this page.

Problem/Motivation

When an anonymous user try to access to a webform :

  • allowed to the current domain
  • and with submissions allowed to anonymous users

the hook_webform_access return an access result forbidden and the page trigger an access denied exception.

Steps to reproduce

  1. Create a webform
  2. Allow anonymous users to create submissions from the access tab in webform settings
  3. Add a domain in "Domain access" field from webform configuration
  4. Go to the webform page url from the selected domain in anonymous context
  5. The webform page trigger an access denied exception

Proposed resolution

Update the hook_webform_access from the module to manage anonymous user use case

CommentFileSizeAuthor
#2 domain_access_webform--anonymous-user.diff840 bytesayalon
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

guenole created an issue. See original summary.

ayalon’s picture

StatusFileSize
new840 bytes

I can confirm the issue. An anonymous user does not have a domain assigned, and therefore the access is denied.

Every anonymous user should at least be granted the current domain. Else there is no way to ever access a webform.

lammensj made their first commit to this issue’s fork.