Skip to content

User data backend

Introduction

The Entity Access Password User Data Backend sub-module (entity_access_password_user_data_backend) allows to store password access in the user data backend (default backend is the database) for persistent storage of granted access.

As the data is per user, anonymous users can not benefit from this backend.

Settings

The settings page is available on /admin/config/content/entity_access_password/user_data/settings, with the "Administer Entity Access Password" permission.

Invalidate accesses when the password changes

If checked, the accesses granted by entering a password are no more valid once this password changes, and users have to enter the new password. If unchecked, the accesses are kept until they are purged with the forms below.

  • The option is enabled by default on new installs, and disabled on sites updated from a previous version, to keep the previous behavior.
  • The accesses granted manually by administrators, with the forms below, are always kept, whatever the option.
  • Saving an entity or a field without entering a new password does not invalidate the accesses. Entering the same password again does.
  • When an entity has several password fields, changing any of their passwords invalidates the accesses of this level (entity or bundle).

Before enabling the option on an updated site: the accesses stored before the option existed, including the ones granted manually by administrators, are not linked to the password which granted them. Once the option is enabled, they are no more valid: users have to enter the passwords again and administrators have to grant the manual accesses again. Disabling the option makes them valid again, as they are not deleted.

Forms to manage user data

To be able to manage the user data (grant/revoke access), the module provides forms for:

  • the global level password: /admin/config/content/entity_access_password/user_data/global
  • the bundle level passwords: /admin/config/content/entity_access_password/user_data/[ENTITY_TYPE_ID]/[ENTITY_BUNDLE], listed on /admin/config/content/entity_access_password/user_data
  • the entity level passwords: /entity_access_password_user_data_backend/[ENTITY_TYPE_ID]/[ENTITY_BUNDLE]/[ENTITY_ID]

For the entity level password form:

  • a tab is provided to access the form on the entity (if the entity has a canonical page and/or a dedicated edit form),
  • an operation link is provided.

For entities without dedicated page, like Paragraphs, you will need to create yourself admin views to have operation links or generate link with another way to access the entity level password form.

It also provides a form to control all the access levels per user on /user/{user}/password_user_data, a tab is provided on the user profile to access this form.

Access

Access to those forms is controlled by permissions:

  • Access global user data form: for the global level password.
  • Access bundle user data form: for the bundle level passwords.
  • Access entity user data form: for the entity level passwords and the user also needs to be able to edit the entity.
  • Access user's user data form: for the form on the user entity.