Class PreAuthorizeReactiveAuthorizationManager
java.lang.Object
org.springframework.security.authorization.method.PreAuthorizeReactiveAuthorizationManager
- All Implemented Interfaces:
ReactiveAuthorizationManager<org.aopalliance.intercept.MethodInvocation>
public final class PreAuthorizeReactiveAuthorizationManager
extends Object
implements ReactiveAuthorizationManager<org.aopalliance.intercept.MethodInvocation>
A
ReactiveAuthorizationManager which can determine if an Authentication
has access to the MethodInvocation by evaluating an expression from the
PreAuthorize annotation.- Since:
- 5.8
-
Constructor Summary
ConstructorsConstructorDescriptionPreAuthorizeReactiveAuthorizationManager(MethodSecurityExpressionHandler expressionHandler) -
Method Summary
Modifier and TypeMethodDescriptionreactor.core.publisher.Mono<AuthorizationDecision>check(reactor.core.publisher.Mono<Authentication> authentication, org.aopalliance.intercept.MethodInvocation mi) Determines if anAuthenticationhas access to theMethodInvocationby evaluating an expression from thePreAuthorizeannotation.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.security.authorization.ReactiveAuthorizationManager
verify
-
Constructor Details
-
PreAuthorizeReactiveAuthorizationManager
public PreAuthorizeReactiveAuthorizationManager() -
PreAuthorizeReactiveAuthorizationManager
-
-
Method Details
-
check
public reactor.core.publisher.Mono<AuthorizationDecision> check(reactor.core.publisher.Mono<Authentication> authentication, org.aopalliance.intercept.MethodInvocation mi) Determines if anAuthenticationhas access to theMethodInvocationby evaluating an expression from thePreAuthorizeannotation.- Specified by:
checkin interfaceReactiveAuthorizationManager<org.aopalliance.intercept.MethodInvocation>- Parameters:
authentication- theMonoof theAuthenticationto checkmi- theMethodInvocationto check- Returns:
- a
Monoof theAuthorizationDecisionor an emptyMonoif thePreAuthorizeannotation is not present
-