Class AuthenticationInterceptor
- java.lang.Object
-
- jadex.bridge.service.component.interceptors.AbstractApplicableInterceptor
-
- jadex.bridge.service.component.interceptors.ComponentThreadInterceptor
-
- jadex.bridge.service.component.interceptors.AbstractLRUApplicableInterceptor
-
- jadex.bridge.service.component.interceptors.AuthenticationInterceptor
-
- All Implemented Interfaces:
IServiceInvocationInterceptor
public class AuthenticationInterceptor extends AbstractLRUApplicableInterceptor
Interceptor that can be used to realize authenticated end-to-end communication. - verifies that a call is authenticated by checking the requested/annotated role(s) against the actual role(s) authenticated by the security service.
-
-
Field Summary
Fields Modifier and Type Field Description protected boolean
send
The mode (send or receive).-
Fields inherited from class jadex.bridge.service.component.interceptors.AbstractLRUApplicableInterceptor
applicables
-
Fields inherited from class jadex.bridge.service.component.interceptors.ComponentThreadInterceptor
ia
-
-
Constructor Summary
Constructors Constructor Description AuthenticationInterceptor(IInternalAccess ia, boolean send)
Create a new AuthenticationInterceptor.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
customIsApplicable(ServiceInvocationContext context)
Test if the interceptor is applicable.IFuture<java.lang.Void>
execute(ServiceInvocationContext context)
Execute the interceptor.protected boolean
isAuthenticated(java.lang.annotation.Annotation anno)
Check if an annotation belongs to the supported types of pre/postconditions.-
Methods inherited from class jadex.bridge.service.component.interceptors.AbstractLRUApplicableInterceptor
isApplicable
-
Methods inherited from class jadex.bridge.service.component.interceptors.ComponentThreadInterceptor
getComponent
-
-
-
-
Constructor Detail
-
AuthenticationInterceptor
public AuthenticationInterceptor(IInternalAccess ia, boolean send)
Create a new AuthenticationInterceptor.
-
-
Method Detail
-
customIsApplicable
public boolean customIsApplicable(ServiceInvocationContext context)
Test if the interceptor is applicable.- Specified by:
customIsApplicable
in classAbstractLRUApplicableInterceptor
- Returns:
- True, if applicable.
-
isAuthenticated
protected boolean isAuthenticated(java.lang.annotation.Annotation anno)
Check if an annotation belongs to the supported types of pre/postconditions.
-
execute
public IFuture<java.lang.Void> execute(ServiceInvocationContext context)
Execute the interceptor.- Parameters:
context
- The invocation context.
-
-