Security in Spring Integration
Introduction
Spring Integration provides integration with the
Spring Security project
to allow role based security checks to be applied to channel send and receive invocations.
Securing channels
Spring Integration provides the interceptor ChannelSecurityInterceptor, which extends
AbstractSecurityInterceptor and intercepts send and receive calls on the channel. Access decisions
are then made with reference to ChannelInvocationDefinitionSource which provides the definition of
the send and receive security constraints. The interceptor requires that a valid SecurityContext
has been established by authenticating with Spring Security, see the Spring Security reference documentation for details.
Namespace support is provided to allow easy configuration of security constraints. This consists of the secured channels tag which allows
definition of one or more channel name patterns in conjunction with a definition of the security configuration for send and receive. The pattern
is a java.util.regexp.Pattern.
]]>
By default the secured-channels namespace element expects a bean named authenticationManager which implements
AuthenticationManager and a bean named accessDecisionManager which implements
AccessDecisionManager. Where this is not the case references to the appropriate beans can be configured
as attributes of the secured-channels element as below.
]]>