de.itsvs.cwtrpc.security
Class RpcSessionManagementFilter
java.lang.Object
org.springframework.web.filter.GenericFilterBean
de.itsvs.cwtrpc.security.RpcSessionManagementFilter
- All Implemented Interfaces:
- Filter, BeanNameAware, DisposableBean, InitializingBean, ServletContextAware
public class RpcSessionManagementFilter
- extends GenericFilterBean
- Since:
- 0.9
- Author:
- Volker Schmidt
|
Method Summary |
void |
afterPropertiesSet()
|
static boolean |
appliedSessionAuthenticationStrategy(HttpServletRequest request,
SessionAuthenticationStrategy strategy)
|
protected void |
applySessionAuthenticationStrategy(Authentication authentication,
HttpServletRequest request,
HttpServletResponse response)
|
void |
doFilter(ServletRequest request,
ServletResponse response,
FilterChain chain)
|
AuthenticationFailureHandler |
getAuthenticationFailureHandler()
|
AuthenticationTrustResolver |
getAuthenticationTrustResolver()
|
RedirectStrategy |
getInvalidSessionRedirectStrategy()
|
String |
getInvalidSessionUrl()
|
RpcHttpSessionStrategy |
getRpcHttpSessionStrategy()
|
SecurityContextRepository |
getSecurityContextRepository()
|
SessionAuthenticationStrategy |
getSessionAuthenticationStrategy()
|
protected void |
invalidateSession(HttpServletRequest request)
|
protected boolean |
process(HttpServletRequest request,
HttpServletResponse response)
|
protected boolean |
processNewContext(HttpServletRequest request,
HttpServletResponse response)
|
protected boolean |
processUnauthenticatedRequest(HttpServletRequest request,
HttpServletResponse response,
Authentication authentication)
|
static void |
saveAppliedSessionAuthenticationStrategy(HttpServletRequest request,
SessionAuthenticationStrategy strategy)
|
protected boolean |
saveSecurityContext(HttpServletRequest request,
HttpServletResponse response,
Authentication authentication)
|
void |
setAuthenticationFailureHandler(AuthenticationFailureHandler authenticationFailureHandler)
|
void |
setInvalidSessionRedirectStrategy(RedirectStrategy invalidSessionRedirectStrategy)
|
void |
setInvalidSessionUrl(String invalidSessionUrl)
|
void |
setRpcHttpSessionStrategy(RpcHttpSessionStrategy rpcHttpSessionStrategy)
|
void |
setSecurityContextRepository(SecurityContextRepository securityContextRepository)
|
void |
setSessionAuthenticationStrategy(SessionAuthenticationStrategy sessionAuthenticationStrategy)
|
protected void |
unsuccessfulAuthentication(HttpServletRequest request,
HttpServletResponse response,
AuthenticationException exception)
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
PROCESSED_ALREADY_ATTR_NAME
protected static final String PROCESSED_ALREADY_ATTR_NAME
APPLIED_SESSION_AUTHENTICATION_STRATEGIES_ATTR_NAME
protected static final String APPLIED_SESSION_AUTHENTICATION_STRATEGIES_ATTR_NAME
INVALID_SESSION_TEXT
protected static final String INVALID_SESSION_TEXT
- See Also:
- Constant Field Values
RpcSessionManagementFilter
public RpcSessionManagementFilter()
saveAppliedSessionAuthenticationStrategy
public static void saveAppliedSessionAuthenticationStrategy(HttpServletRequest request,
SessionAuthenticationStrategy strategy)
appliedSessionAuthenticationStrategy
public static boolean appliedSessionAuthenticationStrategy(HttpServletRequest request,
SessionAuthenticationStrategy strategy)
getSecurityContextRepository
public SecurityContextRepository getSecurityContextRepository()
setSecurityContextRepository
public void setSecurityContextRepository(SecurityContextRepository securityContextRepository)
getAuthenticationFailureHandler
public AuthenticationFailureHandler getAuthenticationFailureHandler()
setAuthenticationFailureHandler
public void setAuthenticationFailureHandler(AuthenticationFailureHandler authenticationFailureHandler)
getSessionAuthenticationStrategy
public SessionAuthenticationStrategy getSessionAuthenticationStrategy()
setSessionAuthenticationStrategy
public void setSessionAuthenticationStrategy(SessionAuthenticationStrategy sessionAuthenticationStrategy)
getAuthenticationTrustResolver
public AuthenticationTrustResolver getAuthenticationTrustResolver()
getInvalidSessionRedirectStrategy
public RedirectStrategy getInvalidSessionRedirectStrategy()
setInvalidSessionRedirectStrategy
public void setInvalidSessionRedirectStrategy(RedirectStrategy invalidSessionRedirectStrategy)
getInvalidSessionUrl
public String getInvalidSessionUrl()
setInvalidSessionUrl
public void setInvalidSessionUrl(String invalidSessionUrl)
getRpcHttpSessionStrategy
public RpcHttpSessionStrategy getRpcHttpSessionStrategy()
setRpcHttpSessionStrategy
public void setRpcHttpSessionStrategy(RpcHttpSessionStrategy rpcHttpSessionStrategy)
afterPropertiesSet
public void afterPropertiesSet()
throws ServletException
- Specified by:
afterPropertiesSet in interface InitializingBean- Overrides:
afterPropertiesSet in class GenericFilterBean
- Throws:
ServletException
doFilter
public void doFilter(ServletRequest request,
ServletResponse response,
FilterChain chain)
throws IOException,
ServletException
- Throws:
IOException
ServletException
process
protected boolean process(HttpServletRequest request,
HttpServletResponse response)
throws IOException,
ServletException
- Throws:
IOException
ServletException
processNewContext
protected boolean processNewContext(HttpServletRequest request,
HttpServletResponse response)
throws IOException,
ServletException
- Throws:
IOException
ServletException
saveSecurityContext
protected boolean saveSecurityContext(HttpServletRequest request,
HttpServletResponse response,
Authentication authentication)
throws IOException,
ServletException
- Throws:
IOException
ServletException
applySessionAuthenticationStrategy
protected void applySessionAuthenticationStrategy(Authentication authentication,
HttpServletRequest request,
HttpServletResponse response)
throws IOException,
ServletException
- Throws:
IOException
ServletException
unsuccessfulAuthentication
protected void unsuccessfulAuthentication(HttpServletRequest request,
HttpServletResponse response,
AuthenticationException exception)
throws IOException,
ServletException
- Throws:
IOException
ServletException
processUnauthenticatedRequest
protected boolean processUnauthenticatedRequest(HttpServletRequest request,
HttpServletResponse response,
Authentication authentication)
throws IOException,
ServletException
- Throws:
IOException
ServletException
invalidateSession
protected void invalidateSession(HttpServletRequest request)
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.