Uploaded image for project: 'Jackrabbit Oak'
  1. Jackrabbit Oak
  2. OAK-3775

Inconsistency between Node.getPrimaryType and Node.isNodeType

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 1.3.13, 1.4
    • core, jcr
    • None

    Description

      Steps:

      1. Create a node structure say /node1/node2 (node2 should be nt:hierarchyNode type node)
      2. Create a testuser and grant read permission on whole repository.
      3. Grant permission jcr:read to testuser on node2.
      3. On node2, deny jcr:read to testuser with rep:glob=/*

      Execute the following from testuser's session:

      • node.getPrimaryNodeType().isNodeType(JcrConstants.NT_HIERARCHYNODE)
      • node.isNodeType(JcrConstants.NT_HIERARCHYNODE)

      where node refers to node2 created above. The first expression returns true but the second returns false.
      Expected: both should return true.

      Attachments

        1. OAK-3775.patch
          14 kB
          Angela Schreiber

        Issue Links

          Activity

            People

              angela Angela Schreiber
              amrverma Amrit Verma
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: