本文整理汇总了Java中org.jasig.cas.client.util.HttpServletRequestWrapperFilter类的典型用法代码示例。如果您正苦于以下问题:Java HttpServletRequestWrapperFilter类的具体用法?Java HttpServletRequestWrapperFilter怎么用?Java HttpServletRequestWrapperFilter使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
HttpServletRequestWrapperFilter类属于org.jasig.cas.client.util包,在下文中一共展示了HttpServletRequestWrapperFilter类的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: init
import org.jasig.cas.client.util.HttpServletRequestWrapperFilter; //导入依赖的package包/类
public void init(FilterConfig filterConfig) throws ServletException {
String casServerLoginUrl = "http://sso.jadyer.com:8080/cas-server-web/login";
String casServerUrlPrefix = "http://sso.jadyer.com:8080/cas-server-web";
String casClientServerName = "http://boss.jadyer.com:8080";
AuthenticationFilter casAuthenticationFilter = new AuthenticationFilter();
casAuthenticationFilter.setCasServerLoginUrl(casServerLoginUrl);
casAuthenticationFilter.setServerName(casClientServerName);
Cas20ProxyReceivingTicketValidationFilter casTicketValidationFilter = new Cas20ProxyReceivingTicketValidationFilter();
casTicketValidationFilter.setServerName(casClientServerName);
casTicketValidationFilter.setTicketValidator(new Cas20ServiceTicketValidator(casServerUrlPrefix));
filters[0] = new SingleSignOutFilter();
// filters[1] = new AuthenticationFilter();
// filters[2] = new Cas20ProxyReceivingTicketValidationFilter();
filters[1] = casAuthenticationFilter;
filters[2] = casTicketValidationFilter;
filters[3] = new HttpServletRequestWrapperFilter();
filters[4] = new AssertionThreadLocalFilter();
for(Filter obj : filters){
System.out.println("[复合Filter]-->Initializing Filter defined in ApplicationContext: '" + obj.toString() + "'");
obj.init(filterConfig);
}
}
示例2: casHttpServletRequestWrapperFilter
import org.jasig.cas.client.util.HttpServletRequestWrapperFilter; //导入依赖的package包/类
@Bean
public FilterRegistrationBean casHttpServletRequestWrapperFilter() {
final FilterRegistrationBean reqWrapperFilter = new FilterRegistrationBean();
reqWrapperFilter.setFilter(new HttpServletRequestWrapperFilter());
if (this.configProps.getRequestWrapperUrlPatterns().size() > 0) {
reqWrapperFilter.setUrlPatterns(this.configProps.getRequestWrapperUrlPatterns());
}
reqWrapperFilter.setOrder(3);
if (this.casClientConfigurer != null) {
this.casClientConfigurer.configureHttpServletRequestWrapperFilter(reqWrapperFilter);
}
return reqWrapperFilter;
}