portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject cvs commit: jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/turbine TurbineAuthentication.java
Date Sat, 08 Jun 2002 15:11:07 GMT
taylor      2002/06/08 08:11:07

  Modified:    src/java/org/apache/jetspeed/services/security/turbine Tag:
                        security_14 TurbineAuthentication.java
  Added:       src/java/org/apache/jetspeed/services Tag: security_14
                        JetspeedAuthentication.java
               src/java/org/apache/jetspeed/services/security Tag:
                        security_14 CredentialsManagement.java
  Log:
  - Credentials management
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +140 -0    jakarta-jetspeed/src/java/org/apache/jetspeed/services/Attic/JetspeedAuthentication.java
  
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.1   +126 -0    jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/Attic/CredentialsManagement.java
  
  
  
  
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.7   +24 -16    jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/turbine/Attic/TurbineAuthentication.java
  
  Index: TurbineAuthentication.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/turbine/Attic/TurbineAuthentication.java,v
  retrieving revision 1.1.2.6
  retrieving revision 1.1.2.7
  diff -u -r1.1.2.6 -r1.1.2.7
  --- TurbineAuthentication.java	7 Jun 2002 10:02:07 -0000	1.1.2.6
  +++ TurbineAuthentication.java	8 Jun 2002 15:11:07 -0000	1.1.2.7
  @@ -90,7 +90,7 @@
    * This service does not use any of the Turbine security or user management classes.
    * 
    * @author <a href="mailto:david@bluesunrise.com">David Sean Taylor</a>
  - * @version $Id: TurbineAuthentication.java,v 1.1.2.6 2002/06/07 10:02:07 taylor Exp $
  + * @version $Id: TurbineAuthentication.java,v 1.1.2.7 2002/06/08 15:11:07 taylor Exp $
    */
                                                                
   public class TurbineAuthentication  extends    TurbineBaseService
  @@ -147,10 +147,13 @@
           try
           {
               user.updateLastLogin();
  -            putUserIntoContext(user);
  +            JetspeedRunData data = putUserIntoContext(user);
  +            getRunData().save();
  +
           }
           catch (Exception e)
           {
  +            putUserIntoContext(JetspeedSecurity.getAnonymousUser());
               throw new LoginException("Failed to update last login ", e);
           }
   
  @@ -230,30 +233,35 @@
   
       ////////////////////////////////////////////////////////////////////////////
   
  -    protected JetspeedUser getUserFromContext()
  +    protected JetspeedRunData getRunData()
       {
  +        JetspeedRunData rundata = null;
           if (this.runDataService != null)
           {
  -            JetspeedRunData rundata = this.runDataService.getCurrentRunData();
  -            if (rundata != null)
  -            {
  -                JetspeedUser user = (JetspeedUser)rundata.getUser();
  +            rundata = this.runDataService.getCurrentRunData();
  +        }
  +        return rundata;=
  +    }
   
  -            }
  +    protected JetspeedUser getUserFromContext()
  +    {
  +        JetspeedRunData rundata = getRunData();
  +        JetspeedUser user = null;
  +        if (rundata != null)
  +        {
  +            user = (JetspeedUser)rundata.getUser();
           }
  -        return null;
  +        return user;
       }
   
  -    protected void putUserIntoContext(JetspeedUser user)
  +    protected JetspeedRunData putUserIntoContext(JetspeedUser user)
       {
  -        if (this.runDataService != null)
  +        JetspeedRunData rundata = getRunData();
  +        if (rundata != null)
           {
  -            JetspeedRunData rundata = this.runDataService.getCurrentRunData();
  -            if (rundata != null)
  -            {
  -                rundata.setUser(user);
  -            }
  +            rundata.setUser(user);
           }
  +        return rundata;
       }
   
   
  
  
  

--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


Mime
View raw message