Uploaded image for project: 'Juneau'
  1. Juneau
  2. JUNEAU-108

AccessDeniedException should cause HTTP 401 response.

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 8.0.0
    • 8.1.0
    • Code
    • None

    Description

      If a method throws org.springframework.security.access.AccessDeniedException, it should immediately rethrow an Unauthorized exception.  

      This exception is thrown when @Secured() is used on a method in Spring.  This would help with Spring integration.

      Perhaps we could define a setting that allows you to specify default exception responses based on exception name patterns:

      e.g.

      { 401: "*AccessDeniedException", 404: "EmptyResult*"}

       

      Attachments

        Activity

          People

            jamesbognar James Bognar
            jamesbognar James Bognar
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: