Spring Security
  1. Spring Security
  2. SEC-2150

Annotating at class level does not protected Spring Data Repositories methods that are not overriden

    Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.2.6, 4.0.0.RC1
    • Component/s: Core
    • Labels:
      None

      Description

      When annotating an interface at the class level (rather than the method level), only the methods defined on the interface are protected. This makes sense, but is inconvenient when working with Something like Spring Data. It would be nice if one could apply the annotation to super interfaces (or a subset of interfaces)

        Issue Links

          Activity

          Hide
          Rob Winch added a comment -

          Both the PreAuthorize & Secured annotations should now work. The JSR annotations will not work since JSR-256 states that the annotations have no impact on interfaces.

          Show
          Rob Winch added a comment - Both the PreAuthorize & Secured annotations should now work. The JSR annotations will not work since JSR-256 states that the annotations have no impact on interfaces.
          Hide
          Eric Sirianni added a comment -

          This JIRA seems to imply that method-level security annotations on Spring Data Repositories should work. However, I'm getting errors when trying apply them – please see DATAJPA-694. Rob - do you have any thoughts?

          Show
          Eric Sirianni added a comment - This JIRA seems to imply that method-level security annotations on Spring Data Repositories should work. However, I'm getting errors when trying apply them – please see DATAJPA-694 . Rob - do you have any thoughts?

            People

            • Assignee:
              Rob Winch
              Reporter:
              Rob Winch
            • Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: