Problem/Motivation

https://git.drupalcode.org/security/185463-weight-security/-/work_items/1 was closed opting to resolve this security issue through public hardening.

The module doesn't sufficiently check access when saving weights submitted through its Views "weight selector" field. Any user who can view such a view can change the weight of every entity it lists, including entities they are not normally allowed to edit.

Steps to reproduce

  1. As an administrator, adding a "Weight" field (field_weight) to the "Article" content type and creating a page view of Article content that includes the field "Content: Weight Selector (field_weight)" and is accessible to users with the "View published content" permission
  2. As an administrator, creating some Article nodes
  3. As an anonymous user (or any user with only the "View published content" permission), opening the view page, changing the weight select lists (or dragging rows, if the view uses the Table format) and clicking "Save"

Proposed resolution

This is a change from previous behavior and might inadvertently impact some use cases. However, lets require permission to edit each entity and its weight field in the Views weight selector field.

Remaining tasks

User interface changes

API changes

Sites that let users reorder content they cannot edit must now grant them edit access.

Data model changes

Issue fork weight-3639203

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

heddn created an issue. See original summary.

  • heddn committed ff70738f on 8.x-3.x
    fix: #3639203 Require update access to save weights from the Views...
heddn’s picture

Status: Active » Fixed

This was already RTBC in the private security tracker before it was decided to publicly resolve. Therefore just merging it.

Now that this issue is closed, review the contribution record.

As a contributor, attribute any organization that helped you, or if you volunteered your own time.

Maintainers, credit people who helped resolve this issue.

heddn’s picture