Hi everyone,
I have been searching on the web for a few hours now and I am seriously confused. Basically what we want is this situation
http://www.ja-sig.org/wiki/display/C...ateway+Example
where if the user is logged in they get some options on the home page and if they're not logged in they don't. We've been using CAS single sign on for authenticating against the whole site so far and now we want to make the home page public but to know the user's credentials if they exist. The problem with just adding an anonymous security role is that the CAS login screen shows up still to try and authenticate when it shouldn't.
So far I'm really confused cause the articles that I can find are pretty scant and contradictory (e.g. different versions, different filter suggestions). We're using Spring 2.5, Spring Security 2.0, Cas Server 3.3 and Cas client 3.1.
This is our web.xml for the single sign on:
And here's the Spring beans for the cas client:Code:<filter> <filter-name>springSecurityFilterChain</filter-name> <filter-class>org.springframework.web.filter.DelegatingFilterProxy</filter-class> </filter> <filter-mapping> <filter-name>springSecurityFilterChain</filter-name> <url-pattern>/*</url-pattern> </filter-mapping>
Anyone have any ideas?Code:<security:http entry-point-ref="casProcessingFilterEntryPoint"> <security:intercept-url pattern="/index.jsp" access="ROLE_ANONYMOUS, ROLE_MEMBER"/> <security:intercept-url pattern="/" access="ROLE_ANONYMOUS, ROLE_MEMBER" /> <security:intercept-url pattern="/**" access="ROLE_MEMBER" /> <security:logout logout-url="/services/logout.html" logout-success-url="/services/loggedOut.html" /> <security:concurrent-session-control max-sessions="1" expired-url="/cas/logout"/> </security:http> <bean id="serviceProperties" class="org.springframework.security.ui.cas.ServiceProperties"> <property name="service" value="http://localhost:8080/j_spring_cas_security_check"/> <property name="sendRenew" value="false"/> </bean> <security:authentication-manager alias="authenticationManager"/> <bean id="casSingleSignOutFilter" class="org.jasig.cas.client.session.SingleSignOutFilter"> <security:custom-filter before="CAS_PROCESSING_FILTER"/> </bean> <bean id="casProcessingFilter" class="org.springframework.security.ui.cas.CasProcessingFilter"> <security:custom-filter after="CAS_PROCESSING_FILTER"/> <property name="authenticationManager" ref="authenticationManager"/> <property name="authenticationFailureUrl" value="/casfailed.jsp"/> <property name="defaultTargetUrl" value="/"/> </bean> <bean id="casProcessingFilterEntryPoint" class="org.springframework.security.ui.cas.CasProcessingFilterEntryPoint"> <property name="loginUrl" value="http://localhost:8080/cas/login"/> <property name="serviceProperties" ref="serviceProperties"/> </bean> <bean id="casAuthenticationProvider" class="org.springframework.security.providers.cas.CasAuthenticationProvider"> <security:custom-authentication-provider /> <property name="userDetailsService" ref="userCredentialsDao"/> <property name="serviceProperties" ref="serviceProperties" /> <property name="ticketValidator"> <bean class="org.jasig.cas.client.validation.Cas20ServiceTicketValidator"> <constructor-arg index="0" value="http://localhost:8080/cas" /> </bean> </property> <property name="key" value="an_id_for_this_auth_provider_only"/> </bean>


