Repository navigation
MCR-3856 Check create-derivate permission on parent object - #3191
Open
sebhofmann wants to merge 1 commit into
Open
sebhofmann wants to merge 1 commit into
sebhofmann wants to merge 1 commit into
Conversation
Creating a derivate checked the pool privilege create-{base} / create-derivate,
which is not bound to an object. The permission create-derivate is now checked
on the parent object. The writedb check on the parent object is unchanged.
BREAKING CHANGE: the pool privilege no longer applies to derivates. Rules for
the permission create-derivate have to be defined for the parent objects.
sebhofmann
force-pushed
the
issues/MCR-3856-Check_create-derivate_permission_on_parent_object
branch
from
October 26, 2026 15:47
1567149 to
6b1e3b5
Compare
sebhofmann
marked this pull request as ready for review
October 26, 2026 16:08
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Link to jira.
Creating a derivate only checked the pool privilege
create-{base}/create-derivate, which is not bound to an object. The permissioncreate-derivateis now checked on the parent object, so ACL rules can allow or deny it per object. Thewritedbcheck on the parent object is unchanged, so the new permission can only restrict.Changes:
MCRMetadataManager.create(MCRDerivate): checkscreate-derivateon the parent object instead of the pool privilege.MCRCreateDerivateServletandMCRDefaultUploadHandler: checkcreate-derivateon the object.MCR.Access.Strategy.CreatorPermissionsnow containscreate-derivate, so creators can still add derivates to their objects.Rules are resolved by the configured strategy.
MCRDerivateIDStrategy(default) only looks at rules for the exact object ID, strategies with fallbacks (e.g.MIRStrategy) also resolvedefault_{base},default_{type}anddefault.Pull Request Checklist (Author)
Ticket & Documentation
fixed-versionis correctly set in the ticket and matches the PR's target branch (main).Feature & Improvement Specific Checks
Rules for the permission
create-derivatehave to be defined for objects (or viadefault*rules, depending on the strategy). Existing pool rules no longer apply to derivates. The migration guide entry is documented in MCR-3856 Migration 2026.12: create-derivate wird am Elternobjekt geprüft mycore-website#182.Testing
MCR Conventions & Metadata
mycore.properties.Multi-Repo Considerations
MIRrequired?Not yet.
modsdetails-external.xslcheckscreate-derivateas pool privilege and has to check it on the object.