Problem/Motivation

With Taxonomy Permissions installed, unpublished terms become accessible to unauthenticated users.

Steps to reproduce

Unpublish a taxonomy term and visit the term's canonical URL in an anonymous browser window. Should return the 403 page, but returns the term page instead (status code 200).

Proposed resolution

Respect the published state same as in a Drupal standard profile install.

Remaining tasks

Fix the access rules.

User interface changes

API changes

Data model changes

CommentFileSizeAuthor
#3 3465902-3.patch2.97 KBnorman.lol
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

leymannx created an issue. See original summary.

norman.lol’s picture

Category: Bug report » Feature request
norman.lol’s picture

StatusFileSize
new2.97 KB

norman.lol’s picture

Assigned: norman.lol » Unassigned
Status: Active » Fixed
norman.lol’s picture

Assigned: Unassigned » norman.lol
Status: Fixed » Closed (won't fix)

Damn, merging this was premature. I now understand that viewing unpublished terms is part of the business logic of this module. I'll revert the commit.

norman.lol’s picture

Ah, I never merged it. Good.

norman.lol’s picture

Status: Closed (won't fix) » Active

Okay, let's do this differently then. Let's add another permission "view unpublished terms in [vocabulary]" for every vocabulary.

  • leymannx committed e560e365 on 8.x-1.x
    Issue #3465902: Prevent view access to unpublished terms
    
norman.lol’s picture

Status: Active » Fixed

Okay, so in D7 taxonomy terms didn't have a status. That's why this was never part of the D7 version of taxonomy permissions. But D8+ comes with a status for terms and by default from core you have no access to them when they are unpublished. To avoid surprises as stated on the module's description page we should follow this pattern for now. And merge the prior MR as is. And if anybody requires it, we can add the view unpublished permissions. I think this is the way to go.

norman.lol’s picture

Assigned: norman.lol » Unassigned

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.