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

Users can see the full view if they have to embed only permissions and isn't redirected to the login page when UnauthorizedException is thrown

    XMLWordPrintable

    Details

      Description

      Description

      Users can see the full view if they have to embed only permissions

      Current 

       
      User see full view even if they don't have permission

      Expected
      User redirect to Login page

       

      And

       

      Description

      When the user doesn't have permissions (for instance content/read) then eZ\Publish\Core\Base\Exceptions\UnauthorizedException is thrown.

      Current 
      A user is not redirected. An application shows

      The server returned a "500 Internal Server Error".

      In the logs are entries regarding that:

      request.CRITICAL: Uncaught PHP Exception Twig_Error_Runtime: "An exception has been thrown during the rendering of a template ("User does not have access to 'read' 'content'")." at vendor/ezsystems/ezpublish-kernel/eZ/Bundle/EzPublishCoreBundle/Resources/views/pagelayout.html.twig line 11
      Unknown macro: {"exception"}

      Expected
      User redirect to Login page

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              Unassigned
              Reporter:
              mateusz.debinski@ez.no Mateusz Dębiński
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: