Hi Simon,
 
You wrote:
> It might be worthwhile, at least as a workaround, to change the code  
> to attempt an implicit auth at the beginning of the request rather  
> than waiting for it to fail at the end. Something like this:
> 
> In DSpaceServlet.processRequest(), after the lines:
> 
>    // Obtain a context - either create one, or get the one created by
>    // an authentication filter
>    context = UIUtil.obtainContext(request);
> 
> insert (copied from Authenticate.java):
> 
>     if (AuthenticationManager.authenticateImplicit(context, null,
null,
>                  null, request) == AuthenticationMethod.SUCCESS)
>      {
>              Authenticate.loggedIn(context, request,
context.getCurrentUser());
>              log.info(LogManager.getHeader(context, "login",
"type=implicit"));
>       }
> 
> Which should, if my thinking is correct, set up the implicitly  
> authenticated user in the context before any of the actual request is

> processed.
> 
> I should stress that I have not tested this and so it may not work,  
> but it's a problem we're about to hit here because we're currently  
> implementing an auth filter for the university's SSO system. So I  
> almost certainly *will* be testing this before the week is out.
 
Good thinking :-) I've just tried this, and whilst I haven't tested
extensively, it appears to work brilliantly, so thanks a million! I am,
officially, a happy bunny . . . . :-)
 
Now the last problem I have to solve is to capture and embed the
originally requested URL into the login form so that I can provide a
link to our portal SSO system (along with the original URL) to
authenticate un-authenticated users and then enable our portal to
redirect them back to the original URL - I do recall seeing the original
url being put into a session variable when I was perusing the
authentication code the other day, but if anyone has any pointers that
will save me digging through the code and hacking (fairly) aimlessly for
the rest of the afternoon, they would be more than welcome :-)
 
Cheers,
 
Mike
Michael White 
eLearning Developer
Centre for eLearning Development (CeLD) 
S7, The Library 
University of Stirling 
Stirling SCOTLAND 
FK9 4LA 

Email: [EMAIL PROTECTED] 
Tel: +44 (0) 1786 466877 
Fax: +44 (0) 1786 466880 

http://www.is.stir.ac.uk/celd/ <http://www.is.stir.ac.uk/celd/> 

 

-- 
The University of Stirling (a charity registered in Scotland, number
SCO11159) is a university established in Scotland by charter at Stirling,
FK9 4LA.  Privileged/Confidential Information may be contained in this
message.  If you are not the addressee indicated in this message (or
responsible for delivery of the message to such person), you may not
disclose, copy or deliver this message to anyone and any action taken or
omitted to be taken in reliance on it, is prohibited and may be unlawful.
In such case, you should destroy this message and kindly notify the sender
by reply email.  Please advise immediately if you or your employer do not
consent to Internet email for messages of this kind.


-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
DSpace-tech mailing list
DSpace-tech@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/dspace-tech

Reply via email to