[Building Sakai] CASifying Sakai & ContainerLogin "blank page" Issue

Duffy Gillman duffy at rsmart.com
Tue Sep 8 15:29:43 PDT 2009


Hi All,

    I'm in the process of CASifying Sakai and have run into some  
tension between Confluence documentation and the behavior of  
ContainerLogin.  If one uses the Sakai wiki documentation a user is  
dumped at a blank page after ContainerLogin completes the user login.   
I am curious whether other CAS implementers have run into the same  
issue and whether a common solution exists.

    Presently two Confluence pages describe CASifying Sakai:

   http://confluence.sakaiproject.org/display/SAKDEV/CASifying+Sakai
   http://confluence.sakaiproject.org/display/~steve.swinsburg/ 
CASifying+Sakai

In those pages a ServletFilter is placed in front of the sakai-login- 
tool/container path.  A login.url is set in sakai.properties which  
creates a login link in the portal.  That link directs the user to CAS  
with a service URL pointing back to sakai-login-tool/container.  At  
that point the filter validates the CAS ticket, then wraps the  
HttpServletRequest with a custom object which implements  
getRemoteUser() to provide the username under which CAS has validated  
the user.  The ContainerLogin Servlet then logs the user into Sakai  
using the UsageSessionService.login() method.

    This is all well and good and works as described.  The problem is  
that the user progresses no further.  He/she is logged in, but  
receives a blank page.  ContainerLogin is written as a Helper tool.   
As such it presumes the user arrived at sakai-login-tool/container  
from a client tool and attempts to return the user to that client  
tool.  An example of this can be seen in the LoginTool servlet at the  
end of doGet().  In the CAS login case the user actually came from a  
standard HTML link and was not redirected from a client tool.  Thus  
ContainerLogin attempts to redirect the user to a blank URL.

    It seems that the options to resolve this are the following:

1) Modify the portal to setup a redirect to ContainerLogin as a Helper  
tool (eg. set the requisite session variables before redirect),

2) Modify the portal to include the login logic and scrap the use of  
ContainerLogin, or

3) Modify ContainerLogin to redirect to a URL specified in  
sakai.properties

Are there folks who have used this strategy to CASify Sakai?  If so,  
is anyone having success with the instructions as written or have you  
had to create some workaround for the "blank page" problem?  Did you  
use one of these solutions to resolve the "blank page" problem, or did  
you do something else entirely?

Thanks in advance,

    Duffy

------------------------------
Duffy Gillman
Sr. Software Engineer
duffy at rsmart.com






More information about the sakai-dev mailing list