Uploaded image for project: 'eZ Publish / Platform'
  1. eZ Publish / Platform
  2. EZP-26790

Using embedAction does not use view_embed policy

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Critical Critical
    • None
    • 1.6.1, 1.7.0
    • Permissions
    • Debian, PHP 5.6

    Description

      When using ez_content:embedAction to display the embed view of a content, we have an permission error if the user only have view_embed access to the the content. For example, I want to display an embed view of a Image from the Media library and I want the Anonymous user to have only view_embed acces to it.

      The problem comes from eZ\Publish\Core\MVC\Symfony\View\Builder\ContentViewBuilder::buildView() method. In the line :

      $content = $view->isEmbed() ? $this->loadContent($contentId) : $this->loadEmbeddedContent($contentId, $location);

      The loadContent and loadEmbeddedContent must be switched.

      Attachments

        Activity

          People

            Unassigned Unassigned
            dvasconc dvasconc
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated: