CAS官方文档

2026/1/24 8:26:28

Client Configuration Using Spring

Configuration via Spring IoC will depend heavily on DelegatingFilterProxy class. For each filter that will be configured for CAS via Spring, a corresponding DelegatingFilterProxy is needed in the web.xml. As

the SingleSignOutFilter, HttpServletRequestWrapperFilter and AssertionThreadLocalFilterhave no configuration options, we recommend you just configure them in the web.xml

CAS Authentication Filter

org.springframework.web.filter.DelegatingFilterProxy

targetBeanName

authenticationFilter

CAS Authentication Filter /*

Bean Configuration

AuthenticationFilter

name=\

class=\ p:casServerLoginUrl=\ p:renew=\ p:gateway=\

p:service=\ /> Cas10TicketValidationFilter

name=\

class=\ p:service=\>

Saml11TicketValidationFilter

name=\

class=\ p:service=\>

Cas20ProxyReceivingTicketValidationFilter Configuration to validate tickets:

name=\

class=\ p:service=\>

Configuration to accept a Proxy Granting Ticket:

name=\

class=\ p:service=\ p:proxyReceptorUrl=\>

class=\ p:proxyCallbackUrl=\>

Configuration to accept any Proxy Ticket (and Proxy Granting Tickets):

name=\

class=\ p:service=\ p:proxyReceptorUrl=\>

p:proxyCallbackUrl=\>

Configuration to accept Proxy Ticket from a chain (and Proxy Granting Tickets):

name=\

class=\ p:service=\ p:proxyReceptorUrl=\>

http://proxy1 http://proxy2

The specific filters can be configured in the following ways. Please see the JavaDocs included in the distribution for specific required and optional properties:

Client Configuration Using JNDI

Configuring the CAS client via JNDI is essentially the same as configuring the client via the web.xml, except the properties will reside in JNDI and not in the web.xml. All properties that are placed in JNDI should be placed under java:comp/env/cas

We use the following conventions: 1. JNDI will first look in java:comp/env/cas/{SHORT FILTER NAME}/{PROPERTY NAME} (i.e. java:comp/env/cas/AuthenticationFilter/serverName) 2. JNDI will as a last resort look in java:comp/env/cas/{PROPERTY NAME} (i.e. java:comp/env/cas/serverName)

Example

This is an update to the META-INF/context.xml that is included in Tomcat's Manager application:

name=\ override=\ type=\ value=\/>

name=\ override=\

type=\ value=\/>

Configuring Single Sign Out

The Single Sign Out support in CAS consists of configuring one SingleSignOutFilter and

oneContextListener. Please note that if you have configured the CAS Client for Java as Web filters, this filter must come before the other filters as described.

The SingleSignOutFilter can affect character encoding. This becomes most obvious when used in conjunction with applications such as Atlassian Confluence. Its recommended you explicitly configure either the VT Character Encoding Filter or the Spring Character Encoding Filter with explicit encodings.

Configuration

Property

artifactParameterName logoutParameterName frontLogoutParameterName relayStateParameterName eagerlyCreateSessions artifactParameterOverPost casServerUrlPrefix

Description

The ticket artifact parameter name. Defaults toticket Defaults to Defaults to Defaults to Defaults to Defaults to

logoutRequest SAMLRequest RelayState true false

Required

No No No No No No Yes

URL to root of CAS Web application context.

CAS Protocol


CAS官方文档.doc 将本文的Word文档下载到电脑
搜索更多关于: CAS官方文档 的文档
相关推荐
相关阅读
× 游客快捷下载通道(下载后可以自由复制和排版)

下载本文档需要支付 10

支付方式:

开通VIP包月会员 特价:29元/月

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信:xuecool-com QQ:370150219