You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Nitin Gupta (Jira)" <ji...@apache.org> on 2020/05/27 06:20:04 UTC

[jira] [Closed] (OAK-9059) Moving nodes doesn't remove source path(s) from HIDDEN_NESTED_CUGS

     [ https://issues.apache.org/jira/browse/OAK-9059?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Nitin Gupta closed OAK-9059.
----------------------------

> Moving nodes doesn't remove source path(s) from HIDDEN_NESTED_CUGS
> ------------------------------------------------------------------
>
>                 Key: OAK-9059
>                 URL: https://issues.apache.org/jira/browse/OAK-9059
>             Project: Jackrabbit Oak
>          Issue Type: Bug
>          Components: authorization-cug
>            Reporter: Angela Schreiber
>            Assignee: Angela Schreiber
>            Priority: Major
>             Fix For: 1.22.4, 1.30.0
>
>
> when moving a tree that hold a nested CUG structure the HIDDEN_NESTED_CUGS property gets updated to contain the new destination path (i.e. during the second 'add'-phase of the move) but doesn't remove the original source path.
> while permission evaluation is correct, this may lead to {{IllegalArgumentException}} raised by {{org.apache.jackrabbit.oak.commons.PathUtils.relativize}} called during {{NestedCugHook$Diff.childNodeDeleted}}, when the policy node containing the HIDDEN_NESTED_CUGS property is removed later on. 
> proposed fix:
> - clear source-path(s) from HIDDEN_NESTED_CUGS during commits that contain move operation(s)
> - prevent {{NestedCugHook$Diff.childNodeDeleted}} to fail but rather ignore paths that cannot be 'relativized' during the reconnect preparation (i.e. not moving those entries to the hidden property with the next parent CUG upon policy removal). this will also make sure inconsistencies introduced by past move operations get cleared upon policy removal. 



--
This message was sent by Atlassian Jira
(v8.3.4#803005)