Project

General

Profile

Actions

Bug #105183

open

FrontendRestrictionContainer applied in BE context while in workspace

Added by Heiko Fischer 4 months ago. Updated 2 months ago.

Status:
Needs Feedback
Priority:
Should have
Assignee:
-
Category:
Workspaces
Target version:
-
Start date:
2024-10-02
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
11
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

We try to load a model, which has assigned fe_groups, per magic "findBy" method from a repository while being in BE context. Relations on models show the same behaviour.

Problem
When the BE user is in a workspace PageRepository->getWorkspaceVersionOfRecord() is called. There gets a FrontendRestrictionContainer applied to the querybuilder without checking the context:

        // If version found, check if it could have been selected with enableFields on
        // as well:
        $queryBuilder = GeneralUtility::makeInstance(ConnectionPool::class)->getQueryBuilderForTable($table);
        $queryBuilder->setRestrictions(GeneralUtility::makeInstance(FrontendRestrictionContainer::class, $this->context));

This causes models restricted by fe_groups to not be loaded in BE context.

Actions #1

Updated by Benni Mack 2 months ago

  • Status changed from New to Needs Feedback

thank you for report and sorry for not getting back to you sooner.

we've overcome this in v12, can you let me know if this issue persists in v12+?

Actions

Also available in: Atom PDF