Hi,

I have written an authentication handler and, there, I perform the 
authentication. The thing is that, now, I would like to add a cookie to the 
HttpServletResponse, which is not available in the AuthenticationHandler 
interface (the method signature has only the credentials parameter). It is 
possible to have the HttpServletResponse within the authenticate method?

I have come across a successfull handler that is 
SavedRequestAwareAuthenticationSuccessHandler and by extending it, I have the 
HttpServletResponse available. The configuration of the default entry point is:


  <sec:http entry-point-ref="casProcessingFilterEntryPoint" auto-config="false">
    <sec:logout logout-url="/services/logout.html" 
logout-success-url="/services/loggedOut.html"/>
    <sec:custom-filter ref="casProcessingFilter" after="CAS_FILTER"/>
    <sec:intercept-url pattern="/services/*" 
access="${cas.securityContext.serviceProperties.adminRoles}"/>
  </sec:http>

and the activation I have done to use it is:

<bean id="casProcessingFilter" 
class="edu.uoc.authentication.cas.UOCCasAuthenticationFilter"
        p:authenticationManager-ref="casAuthenticationManager"
        p:filterProcessesUrl="/services/j_acegi_cas_security_check">
       
    <property name="authenticationSuccessHandler">
       <bean 
class="edu.uoc.authentication.handler.support.UOCSuccessfulAuthenticationHandler"
           p:alwaysUseDefaultTargetUrl="true"
           p:defaultTargetUrl="/services/manage.html"/>
    </property>
    <property name="authenticationFailureHandler">
      <bean 
class="org.springframework.security.web.authentication.SimpleUrlAuthenticationFailureHandler">
        <constructor-arg index="0" value="/authorizationFailure.html"/>
      </bean>
    </property>
  </bean> 

The problem is that it is only activated when I access the 
https://localhost:8443/cas/services url and I would like to detect as well 
correct login that comes from the cas redirection when I go to 
https://localhost:8443/webapps/welcomeApp

Which configuration I have to change?

Your help would be very appreciated since I have been stuck with this issue for 
some days without succeeding.

Thank you very much.
-- 
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

Reply via email to