Class JSessionStripFilter
- java.lang.Object
-
- edu.cornell.mannlib.vitro.webapp.filters.JSessionStripFilter
-
- All Implemented Interfaces:
javax.servlet.Filter
@WebFilter(filterName="JSession Strip Filter", urlPatterns="/*") public class JSessionStripFilter extends Object implements javax.servlet.FilterReplaces the Response with one that will never put in a jsession. Here is what needs to go into the web.xml:<filter> <filter-name>JSession Strip Filter</filter-name> <filter-class>edu.cornell.mannlib.vitro.filters.JSessionStripFilter</filter-class> </filter> <filter-mapping> <filter-name>JSession Strip Filter</filter-name> <url-pattern>/*</url-pattern> <dispatcher>REQUEST</dispatcher> </filter-mapping>some of this code is from URLRewriteFilter
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classJSessionStripFilter.StripSessionIdWrapperThis is a wrapper that does not encode urls with jsessions
-
Field Summary
Fields Modifier and Type Field Description static StringUSING_JSESSION_STRIP
-
Constructor Summary
Constructors Constructor Description JSessionStripFilter()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voiddestroy()voiddoFilter(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain)voidinit(javax.servlet.FilterConfig filterConfig)
-
-
-
Field Detail
-
USING_JSESSION_STRIP
public static String USING_JSESSION_STRIP
-
-
Method Detail
-
init
public void init(javax.servlet.FilterConfig filterConfig) throws javax.servlet.ServletException- Specified by:
initin interfacejavax.servlet.Filter- Throws:
javax.servlet.ServletException
-
doFilter
public void doFilter(javax.servlet.ServletRequest request, javax.servlet.ServletResponse response, javax.servlet.FilterChain chain) throws IOException, javax.servlet.ServletException- Specified by:
doFilterin interfacejavax.servlet.Filter- Throws:
IOExceptionjavax.servlet.ServletException
-
destroy
public void destroy()
- Specified by:
destroyin interfacejavax.servlet.Filter
-
-