jackrabbit-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Vikas Saurabh <vikas.saur...@gmail.com>
Subject Minimum permissions to carry out a move operation
Date Sun, 13 Oct 2013 12:58:16 GMT
Hi,

Currently, to move a node 'n' under source parent 'p' to destination
parent 'd', jackrabbit requires following permissions:

1. n -> removeNode
2. p -> removeChildNodes
3. d -> addChildNodes
4. whole path from '/' to 'd' -> read
5. d/n -> nodeTypeManagement

I can understand perms 1-3 completely.

But, I am not completely sure of 4. It was added for JCR-3291 [0]. So,
while I don't know if this was the best way to fix the issue, but it's
surely intentional and not an over-sight.

About 5, it was added in [2] and now resides in
SessionMoveOperation.java [3]. Why do we need nodeTypeManagement
during a move?

Thanks,
Vikas

[1] - https://issues.apache.org/jira/browse/JCR-3291
[2] - https://github.com/apache/jackrabbit/blob/483ac4e0a61444a2afa336b0a7e04ddc414addc7/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionImpl.java#L1045
[3] - https://github.com/apache/jackrabbit/blame/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/SessionMoveOperation.java

Mime
View raw message