Thanks for your answer. Here is my configuration file :
<?xml version="1.0" encoding="UTF-8"?> <beans xmlns="http://www.springframework.org/schema/beans" xmlns:sec="http://www.springframework.org/schema/security" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:jee="http://www.springframework.org/schema/jee" xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-3.0.xsd http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security-3.0.xsd http://www.springframework.org/schema/jee http://www.springframework.org/schema/jee/spring-jee-3.0.xsd"> <sec:global-method-security pre-post-annotations="enabled"/> <sec:http entry-point-ref="casProcessingFilterEntryPoint" use-expressions="true"> <sec:intercept-url pattern="/public/**" access="permitAll"/> <sec:intercept-url pattern="/resources/**" access="permitAll"/> <sec:intercept-url pattern="/primefaces_resource/**" access="permitAll"/> <sec:intercept-url pattern="/javax.faces.resource/**" access="permitAll"/> <sec:intercept-url pattern="/**" access="isAuthenticated()"/> <sec:intercept-url pattern="/admin/**" access="hasRole('ROLE_ADMIN')"/> <sec:logout logout-success-url="/cas-logout.xhtml"/> <sec:custom-filter ref="casAuthenticationFilter" after="CAS_FILTER"/> </sec:http> <sec:authentication-manager alias="authenticationManager"> <sec:authentication-provider ref="casAuthenticationProvider"/> </sec:authentication-manager> <bean id="casAuthenticationFilter" class="org.springframework.security.cas.web.CasAuthenticationFilter"> <property name="authenticationManager" ref="authenticationManager"/> <property name="authenticationFailureHandler"> <bean class="org.springframework.security.web.authentication.SimpleUrlAuthenticationFailureHandler"> <property name="defaultFailureUrl" value="/casfailed.xhtml"/> </bean> </property> <property name="authenticationSuccessHandler"> <bean class="org.springframework.security.web.authentication.SimpleUrlAuthenticationSuccessHandler"/> </property> </bean> <bean id="casProcessingFilterEntryPoint" class="org.springframework.security.cas.web.CasAuthenticationEntryPoint"> <property name="loginUrl" value="${casUrl}/login"/> <property name="serviceProperties" ref="serviceProperties"/> </bean> <bean id="casAuthenticationProvider" class="org.springframework.security.cas.authentication.CasAuthenticationProvider"> <property name="userDetailsService" ref="userDetailService"/> <property name="serviceProperties" ref="serviceProperties" /> <property name="ticketValidator"> <bean class="org.jasig.cas.client.validation.Cas20ServiceTicketValidator"> <constructor-arg index="0" value="${casUrl}" /> </bean> </property> <property name="key" value="hotline-myfoncia"/> </bean> <bean id="serviceProperties" class="org.springframework.security.cas.ServiceProperties"> <property name="service" value="${applicationUrl}/j_spring_cas_security_check"/> <property name="sendRenew" value="false"/> </bean> <bean id="saveParamFilter" class="com.foncia.hotlinemyfoncia.web.filter.SaveParamFilter"/> <bean id="userDetailService" class="com.foncia.hotlinemyfoncia.security.ApplicationUserDetailService"/> </beans> applicationUrl is something like : http://myapp.fr/myapp/ and casUrl is https://myhost.fr/cas You're probably right, something may be wrong ! ----- Mail original ----- De: "Marvin S. Addison" <[email protected]> À: [email protected] Envoyé: Vendredi 13 Avril 2012 15:20:22 Objet: Re: [cas-user] CAS + SpringSecurity + orginal url > My application is http://myhost/myapp . If I'm not registred to the app, I'm= > redirected to CAS and when I come back to my app I've lost all my paramete= > rs. This is probably happening due to misconfiguration of the CAS client. Can you share relevant config excerpts? M -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user -- Vincent POUPET - FONCIA Groupe - DPM/DSI Architecte Développements Tel : 01 55 52 54 70 Email : [email protected] Ce message et toutes les pièces jointes sont confidentiels et établis à l'intention exclusive de ses destinataires. Si vous n'êtes pas destinataire de ce message, merci de le détruire et d'en avertir immédiatement l'expéditeur. Toute utilisation ou diffusion non autorisée est interdite. Tout message électronique est susceptible d'altération, FONCIA décline toute responsabilité au titre de ce message s'il a été altéré, déformé ou falsifié. Avant d'imprimer ce mail, pensez à l'environnement. -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-user
