public class NullRunAsManager extends Object implements RunAsManager
RunAsManager
that does nothing.This class should be used if you do not require run-as authenticaiton replacement functionality.
Constructor and Description |
---|
NullRunAsManager() |
Modifier and Type | Method and Description |
---|---|
Authentication |
buildRunAs(Authentication authentication,
Object object,
ConfigAttributeDefinition config)
Returns a replacement
Authentication object for the current secure object invocation, or
null if replacement not required. |
boolean |
supports(Class clazz)
Indicates whether the
RunAsManager implementation is able to provide run-as replacement for
the indicated secure object type. |
boolean |
supports(ConfigAttribute attribute)
Indicates whether this
RunAsManager is able to process the passed
ConfigAttribute . |
public Authentication buildRunAs(Authentication authentication, Object object, ConfigAttributeDefinition config)
RunAsManager
Authentication
object for the current secure object invocation, or
null
if replacement not required.buildRunAs
in interface RunAsManager
authentication
- the caller invoking the secure objectobject
- the secured object being calledconfig
- the configuration attributes associated with the secure object being invokednull
if
the Authentication
should be left as ispublic boolean supports(ConfigAttribute attribute)
RunAsManager
RunAsManager
is able to process the passed
ConfigAttribute
.This allows the AbstractSecurityInterceptor
to check every
configuration attribute can be consumed by the configured AccessDecisionManager
and/or
RunAsManager
and/or AfterInvocationManager
.
supports
in interface RunAsManager
attribute
- a configuration attribute that has been configured against the
AbstractSecurityInterceptor
true
if this RunAsManager
can support the passed configuration attributepublic boolean supports(Class clazz)
RunAsManager
RunAsManager
implementation is able to provide run-as replacement for
the indicated secure object type.supports
in interface RunAsManager
clazz
- the class that is being queriedCopyright © 2017. All rights reserved.