Review main Merged

89172[BUGFIX] Respect `ignoreRootLevelRestriction` for `pid=0` records

Stefan Bürk CR +2 V +2 Easy +11 −6 updated 04/24/25, 12:17

Commit message

With #106382 DataHandler permission check handling has been
streamlined and missed to keep respecting related TCA option
`ignoreRootLevelRestriction` for records handled and saved
on rootLevel (`pid=0`). For example FAL file and file metadata
are stored on `pid=0`, which are no longer editable or
translatable by casual editors.

Based on the change, empty page record are now passed down to
the BE_user `isInWebMount()` throwing an exception because no
`uid` is provided in the empty array.

This change modifies some places to reintroduce checks for the
TCA option `ignoreRootLevelRestriction` when record pid is zero,
not calling `isInWebMount()` with an empty page record.

Review

  • Code review CR +2 Done
    • Christian Kuhn +2
    • André Buchmann +1
    • Benni Mack +1
  • Verified V +2 Done
    • Christian Kuhn +2
    • André Buchmann +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 2

Files 1

Review log 1114

  1. Stefan Bürk uploaded patch set 1 04/18/25, 15:13

  2. Stefan Bürk updated the commit message in patch set 2 04/18/25, 15:17

  3. core-ci voted on patch set 1 V +1 04/18/25, 15:19 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/77943

  4. core-ci voted on patch set 2 V +1 04/18/25, 15:23 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/77944

  5. André Buchmann commented on patch set 2 CR -1 V +1 04/18/25, 21:09

    Patch fixes the issue. Should we have tests to catch those permission errors in future?
  6. Stefan Bürk marked it work in progress 04/22/25, 07:12

  7. Christian Kuhn commented on patch set 2 CR -1 04/24/25, 11:20

    This change is ready for review.
    working on it.
  8. Christian Kuhn uploaded patch set 3 CR -1 V +1 04/24/25, 11:51

  9. Christian Kuhn commented on patch set 3 CR +1 V +1 04/24/25, 11:52

    Reply

    We have close to zero non-admin DH tests, adding one in this case is quite some effort, and I think we'll have to live without them for another while.
  10. Benni Mack voted on patch set 3 CR +1 V +1 04/24/25, 11:54

  11. core-ci voted on patch set 3 V +1 04/24/25, 11:57 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/78122

  12. André Buchmann commented on patch set 3 CR +1 V +1 04/24/25, 11:58

    Fine for me to not add test now
  13. Christian Kuhn voted on patch set 3 CR +2 V +2 04/24/25, 12:08

  14. Christian Kuhn merged patch set 4 04/24/25, 12:17