Uploaded image for project: 'Nuxeo Platform'
  1. Nuxeo Platform
  2. NXP-26526

Fix Document.BlockPermissionInheritance respecting Auth.LoginAs system user

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Not A Bug
    • Affects Version/s: 9.10
    • Fix Version/s: None
    • Component/s: Automation
    • Tags:
    • Backlog priority:
      600
    • Sprint:
      nxfit 10.10.5
    • Story Points:
      3

      Description

      In a simple automation script

        Auth.LoginAs(input, {});
        Document.BlockPermissionInheritance(input, {});
      

      run by a user with no admin privilege, the BlockPermissionInheritance operation throws

      Caused by: org.nuxeo.ecm.core.api.DocumentSecurityException: Failed to invoke operation Document.BlockPermissionInheritance, Privilege 'WriteSecurity' is not granted to 'test'
              at org.nuxeo.ecm.core.api.AbstractSession.checkPermission(AbstractSession.java:215)
              at org.nuxeo.ecm.core.api.AbstractSession.setACP(AbstractSession.java:566)
              at org.nuxeo.ecm.core.api.impl.DocumentModelImpl.setACP(DocumentModelImpl.java:750)
              at org.nuxeo.ecm.automation.core.operations.document.BlockPermissionInheritance.blockPermissionInheritance(BlockPermissionInheritance.java:69)
              at org.nuxeo.ecm.automation.core.operations.document.BlockPermissionInheritance.run(BlockPermissionInheritance.java:53)
      

      EXPECTED: the system user should be able to block the permission inheritance

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 1 hour, 30 minutes
                  1h 30m