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

Fix document access if a bound template is not visible

    XMLWordPrintable

    Details

    • Tags:
    • Backlog priority:
      400

      Description

      When a user has access to a document which is bound to a template he does not have the Read permission on, the page fails to load with the following exception in the logs:

      ERROR [DefaultActionFilter] evaluation of condition #{renditionAction.hasVisibleRenditions('nuxeo:video:conversion,nuxeo:picture:conversion')} failed: returning false
       {{RemoteAddr,10.213.3.23}{RequestURL,http://10.213.0.49:8080/nuxeo/view_documents.faces}{ServletPath,/view_documents.faces}{SessionID,43EFD9C7DA1D09212E927E1BDEF2A0C5.nuxeo}{UserPrincipal,usertest}}javax.el.ELException: org.nuxeo.ecm.core.api.DocumentSecurityException: Privilege 'Read' is not granted to 'usertest'
      ...
      Caused by: org.nuxeo.ecm.core.api.DocumentSecurityException: Privilege 'Read' is not granted to 'usertest'
      	at org.nuxeo.ecm.core.api.AbstractSession.checkPermission(AbstractSession.java:207)
      	at org.nuxeo.ecm.core.api.AbstractSession.getDocument(AbstractSession.java:942)
      	at org.nuxeo.template.adapters.doc.TemplateBasedDocumentAdapterImpl.getSourceTemplateDoc(TemplateBasedDocumentAdapterImpl.java:140)
      	at org.nuxeo.template.adapters.doc.TemplateBasedDocumentAdapterImpl.getSourceTemplate(TemplateBasedDocumentAdapterImpl.java:105)
      	at org.nuxeo.template.adapters.doc.TemplateBasedDocumentAdapterImpl.getTemplateNameForRendition(TemplateBasedDocumentAdapterImpl.java:362)
      	at org.nuxeo.template.rendition.TemplateBasedRenditionProvider.isAvailable(TemplateBasedRenditionProvider.java:23)
      	at org.nuxeo.ecm.platform.rendition.service.RenditionDefinitionRegistry.getRenditionDefinitions(RenditionDefinitionRegistry.java:68)
      	at org.nuxeo.ecm.platform.rendition.service.RenditionServiceImpl.getAvailableRenditionDefinitions(RenditionServiceImpl.java:140)
      	at org.nuxeo.ecm.platform.rendition.service.RenditionServiceImpl.getAvailableRenditions(RenditionServiceImpl.java:371)
      	at org.nuxeo.ecm.platform.rendition.action.RenditionActionBean.getVisibleRenditions(RenditionActionBean.java:84)
      	at org.nuxeo.ecm.platform.rendition.action.RenditionActionBean.hasVisibleRenditions(RenditionActionBean.java:100)
      

        Attachments

          Activity

            People

            • Votes:
              1 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 day
                1d