ch4mpy / spring-addons

Ease spring OAuth2 resource-servers configuration and testing
Apache License 2.0
557 stars 90 forks source link

`GenericMethodSecurityExpressionHandler` should accept expression root suppliers for many authentication type #53

Closed ch4mpy closed 2 years ago

ch4mpy commented 2 years ago

If a GenericMethodSecurityExpressionHandler configured for a given authentication type, let's say OAuthentication<OpenidClaimSet>, then an exception is thrown when an other type of Authentication is in the security context (for instance an AnonymousAuthenticationToken, or whatever else one of the authentication managers can decide)