You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@directory.apache.org by er...@apache.org on 2007/05/11 07:02:31 UTC

svn commit: r537094 - in /directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos: kdc/ kdc/authentication/ kdc/preauthentication/ kdc/ticketgrant/ protocol/ sam/

Author: erodriguez
Date: Thu May 10 22:02:30 2007
New Revision: 537094

URL: http://svn.apache.org/viewvc?view=rev&rev=537094
Log:
Javadocs and minor warning clean-up.

Modified:
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcConfiguration.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/AuthenticationServiceChain.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/BuildReply.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/ConfigureAuthenticationChain.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/GenerateTicket.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/SealReply.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/VerifyPolicy.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/PreAuthenticationChain.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/VerifierBase.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/BuildReply.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/ConfigureTicketGrantingChain.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GenerateTicket.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GetAuthHeader.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/SealReply.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/TicketGrantingServiceChain.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolCodecFactory.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolHandler.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamSubsystem.java
    directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamVerifier.java

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcConfiguration.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcConfiguration.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcConfiguration.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/KdcConfiguration.java Thu May 10 22:02:30 2007
@@ -143,6 +143,8 @@
     /**
      * Creates a new instance with default settings that operates on the
      * {@link DirectoryService} with the specified ID.
+     * 
+     * @param instanceId 
      */
     public KdcConfiguration( String instanceId )
     {
@@ -151,12 +153,23 @@
     }
 
 
+    /**
+     * Creates a new instance of KdcConfiguration.
+     *
+     * @param properties
+     */
     public KdcConfiguration( Map<String, Object> properties )
     {
         this( properties, LoadStrategy.LDAP );
     }
 
 
+    /**
+     * Creates a new instance of KdcConfiguration.
+     *
+     * @param properties
+     * @param strategy
+     */
     public KdcConfiguration( Map<String, Object> properties, int strategy )
     {
         if ( properties == null )
@@ -179,6 +192,11 @@
     }
 
 
+    /**
+     * Returns a Map of the default config.
+     *
+     * @return The default config.
+     */
     public static Map<String, Object> getDefaultConfig()
     {
         Map<String, Object> defaults = new HashMap<String, Object>();
@@ -190,6 +208,12 @@
     }
 
 
+    /**
+     * Returns whether the Dictionary of config is different from this config.
+     *
+     * @param config
+     * @return true if the configs are different.
+     */
     public boolean isDifferent( Dictionary config )
     {
         int port = getPort();
@@ -203,12 +227,22 @@
     }
 
 
+    /**
+     * Returns the name of this service.
+     *
+     * @return The name of this service.
+     */
     public String getName()
     {
         return DEFAULT_NAME;
     }
 
 
+    /**
+     * Returns the primary realm.
+     *
+     * @return The primary realm.
+     */
     public String getPrimaryRealm()
     {
         String key = REALM_KEY;
@@ -222,6 +256,11 @@
     }
 
 
+    /**
+     * Returns the KDC principal.
+     *
+     * @return The KDC principal.
+     */
     public KerberosPrincipal getKdcPrincipal()
     {
         String key = PRINCIPAL_KEY;
@@ -248,12 +287,22 @@
     }
 
 
+    /**
+     * Returns the encryption types.
+     *
+     * @return The encryption types.
+     */
     public EncryptionType[] getEncryptionTypes()
     {
         return encryptionTypes;
     }
 
 
+    /**
+     * Returns the properties.
+     *
+     * @return The properties.
+     */
     public Map<String, Object> getProperties()
     {
         // Request that the krb5key value be returned as binary
@@ -263,6 +312,11 @@
     }
 
 
+    /**
+     * Returns the clock skew.
+     *
+     * @return The clock skew.
+     */
     public long getClockSkew()
     {
         String key = ALLOWABLE_CLOCKSKEW_KEY;
@@ -276,6 +330,11 @@
     }
 
 
+    /**
+     * Returns the port.
+     *
+     * @return The port.
+     */
     public int getPort()
     {
         String key = IP_PORT_KEY;
@@ -289,6 +348,11 @@
     }
 
 
+    /**
+     * Returns the buffer size.
+     *
+     * @return The buffer size.
+     */
     public int getBufferSize()
     {
         String key = BUFFER_SIZE_KEY;
@@ -302,6 +366,11 @@
     }
 
 
+    /**
+     * Returns whether pre-authentication by encrypted timestamp is required.
+     *
+     * @return true if pre-authentication by encrypted timestamp is required.
+     */
     public boolean isPaEncTimestampRequired()
     {
         String key = PA_ENC_TIMESTAMP_REQUIRED_KEY;
@@ -315,6 +384,11 @@
     }
 
 
+    /**
+     * Returns the maximum ticket lifetime.
+     *
+     * @return The maximum ticket lifetime.
+     */
     public long getMaximumTicketLifetime()
     {
         String key = TGS_MAXIMUM_TICKET_LIFETIME_KEY;
@@ -328,6 +402,11 @@
     }
 
 
+    /**
+     * Returns the maximum renewable lifetime.
+     *
+     * @return The maximum renewable lifetime.
+     */
     public long getMaximumRenewableLifetime()
     {
         String key = TGS_MAXIMUM_RENEWABLE_LIFETIME_KEY;
@@ -341,6 +420,11 @@
     }
 
 
+    /**
+     * Returns whether empty addresses are allowed.
+     *
+     * @return true if empty addresses are allowed.
+     */
     public boolean isEmptyAddressesAllowed()
     {
         String key = EMPTY_ADDRESSES_ALLOWED_KEY;
@@ -354,6 +438,11 @@
     }
 
 
+    /**
+     * Returns whether forwardable tickets are allowed.
+     *
+     * @return true if forwardable tickets are allowed.
+     */
     public boolean isForwardableAllowed()
     {
         String key = TGS_FORWARDABLE_ALLOWED_KEY;
@@ -367,6 +456,11 @@
     }
 
 
+    /**
+     * Returns whether proxiable tickets are allowed.
+     *
+     * @return true if proxiable tickets are allowed.
+     */
     public boolean isProxiableAllowed()
     {
         String key = TGS_PROXIABLE_ALLOWED_KEY;
@@ -380,6 +474,11 @@
     }
 
 
+    /**
+     * Returns whether postdated tickets are allowed.
+     *
+     * @return true if postdated tickets are allowed.
+     */
     public boolean isPostdateAllowed()
     {
         String key = TGS_POSTDATE_ALLOWED_KEY;
@@ -393,6 +492,11 @@
     }
 
 
+    /**
+     * Returns whether renewable tickets are allowed.
+     *
+     * @return true if renewable tickets are allowed.
+     */
     public boolean isRenewableAllowed()
     {
         String key = TGS_RENEWABLE_ALLOWED_KEY;

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/AuthenticationServiceChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/AuthenticationServiceChain.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/AuthenticationServiceChain.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/AuthenticationServiceChain.java Thu May 10 22:02:30 2007
@@ -32,6 +32,9 @@
  */
 public class AuthenticationServiceChain extends IoHandlerChain
 {
+    /**
+     * Creates a new instance of AuthenticationServiceChain.
+     */
     public AuthenticationServiceChain()
     {
         addLast( "monitorRequest", new MonitorRequest() );

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/BuildReply.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/BuildReply.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/BuildReply.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/BuildReply.java Thu May 10 22:02:30 2007
@@ -74,7 +74,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/ConfigureAuthenticationChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/ConfigureAuthenticationChain.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/ConfigureAuthenticationChain.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/ConfigureAuthenticationChain.java Thu May 10 22:02:30 2007
@@ -50,7 +50,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/GenerateTicket.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/GenerateTicket.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/GenerateTicket.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/GenerateTicket.java Thu May 10 22:02:30 2007
@@ -38,7 +38,6 @@
 import org.apache.directory.server.kerberos.shared.messages.value.KerberosTime;
 import org.apache.directory.server.kerberos.shared.messages.value.TicketFlags;
 import org.apache.directory.server.kerberos.shared.messages.value.TransitedEncoding;
-import org.apache.directory.shared.ldap.util.StringTools;
 import org.apache.mina.common.IoSession;
 import org.apache.mina.handler.chain.IoHandlerCommand;
 import org.slf4j.Logger;
@@ -195,7 +194,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/SealReply.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/SealReply.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/SealReply.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/SealReply.java Thu May 10 22:02:30 2007
@@ -53,7 +53,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/VerifyPolicy.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/VerifyPolicy.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/VerifyPolicy.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/authentication/VerifyPolicy.java Thu May 10 22:02:30 2007
@@ -27,8 +27,6 @@
 import org.apache.directory.server.kerberos.shared.store.PrincipalStoreEntry;
 import org.apache.mina.common.IoSession;
 import org.apache.mina.handler.chain.IoHandlerCommand;
-//import org.slf4j.Logger;
-//import org.slf4j.LoggerFactory;
 
 
 /**
@@ -37,10 +35,8 @@
  */
 public class VerifyPolicy implements IoHandlerCommand
 {
-    /** the log for this class */
-//    private static final Logger log = LoggerFactory.getLogger( VerifyPolicy.class );
     private String contextKey = "context";
-    
+
 
     public void execute( NextCommand next, IoSession session, Object message ) throws Exception
     {
@@ -61,11 +57,12 @@
         {
             throw new KerberosException( ErrorType.KDC_ERR_CLIENT_REVOKED );
         }
-        next.execute( session, message ); 
+
+        next.execute( session, message );
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/PreAuthenticationChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/PreAuthenticationChain.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/PreAuthenticationChain.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/PreAuthenticationChain.java Thu May 10 22:02:30 2007
@@ -28,6 +28,9 @@
  */
 public class PreAuthenticationChain extends IoHandlerChain
 {
+    /**
+     * Creates a new instance of PreAuthenticationChain.
+     */
     public PreAuthenticationChain()
     {
         addLast( "verifySam", new VerifySam() );

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/VerifierBase.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/VerifierBase.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/VerifierBase.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/preauthentication/VerifierBase.java Thu May 10 22:02:30 2007
@@ -41,12 +41,13 @@
     private String contextKey = "context";
 
 
-    public String getContextKey()
-    {
-        return ( this.contextKey );
-    }
-
-
+    /**
+     * Prepares a pre-authentication error message containing required
+     * encryption types.
+     *
+     * @param encryptionTypes
+     * @return The error message as bytes.
+     */
     public byte[] preparePreAuthenticationError( EncryptionType[] encryptionTypes )
     {
         PreAuthenticationData[] paDataSequence = new PreAuthenticationData[2];
@@ -88,5 +89,11 @@
         {
             return null;
         }
+    }
+
+
+    protected String getContextKey()
+    {
+        return ( this.contextKey );
     }
 }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/BuildReply.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/BuildReply.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/BuildReply.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/BuildReply.java Thu May 10 22:02:30 2007
@@ -71,7 +71,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/ConfigureTicketGrantingChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/ConfigureTicketGrantingChain.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/ConfigureTicketGrantingChain.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/ConfigureTicketGrantingChain.java Thu May 10 22:02:30 2007
@@ -49,7 +49,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GenerateTicket.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GenerateTicket.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GenerateTicket.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GenerateTicket.java Thu May 10 22:02:30 2007
@@ -122,12 +122,6 @@
     }
 
 
-    public String getContextKey()
-    {
-        return ( this.contextKey );
-    }
-
-
     private void processFlags( KdcConfiguration config, KdcRequest request, Ticket tgt,
         EncTicketPartModifier newTicketBody ) throws KerberosException
     {
@@ -280,7 +274,7 @@
              new_tkt.starttime+client.max_life,
              new_tkt.starttime+server.max_life,
              */
-            List minimizer = new ArrayList();
+            List<KerberosTime> minimizer = new ArrayList<KerberosTime>();
             minimizer.add( till );
             minimizer.add( new KerberosTime( now.getTime() + config.getMaximumTicketLifetime() ) );
             minimizer.add( tgt.getEndTime() );
@@ -321,7 +315,7 @@
              new_tkt.starttime+server.max_rlife,
              */
             // TODO - client and server configurable; requires store
-            List minimizer = new ArrayList();
+            List<KerberosTime> minimizer = new ArrayList<KerberosTime>();
 
             /*
              * 'rtime' KerberosTime is OPTIONAL
@@ -333,7 +327,7 @@
 
             minimizer.add( new KerberosTime( now.getTime() + config.getMaximumRenewableLifetime() ) );
             minimizer.add( tgt.getRenewTill() );
-            newTicketBody.setRenewTill( ( KerberosTime ) Collections.min( minimizer ) );
+            newTicketBody.setRenewTill( Collections.min( minimizer ) );
         }
     }
 
@@ -368,5 +362,11 @@
         newTicketBody.setRenewTill( tgt.getRenewTill() );
         newTicketBody.setSessionKey( tgt.getSessionKey() );
         newTicketBody.setTransitedEncoding( tgt.getTransitedEncoding() );
+    }
+
+
+    protected String getContextKey()
+    {
+        return ( this.contextKey );
     }
 }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GetAuthHeader.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GetAuthHeader.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GetAuthHeader.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/GetAuthHeader.java Thu May 10 22:02:30 2007
@@ -44,6 +44,7 @@
 {
     private String contextKey = "context";
 
+
     public void execute( NextCommand next, IoSession session, Object message ) throws Exception
     {
         TicketGrantingContext tgsContext = ( TicketGrantingContext ) session.getAttribute( getContextKey() );
@@ -59,12 +60,6 @@
     }
 
 
-    public String getContextKey()
-    {
-        return ( this.contextKey );
-    }
-
-
     protected ApplicationRequest getAuthHeader( KdcRequest request ) throws KerberosException, IOException
     {
         byte[] undecodedAuthHeader = null;
@@ -87,5 +82,11 @@
         ApplicationRequest authHeader = decoder.decode( undecodedAuthHeader );
 
         return authHeader;
+    }
+
+
+    protected String getContextKey()
+    {
+        return ( this.contextKey );
     }
 }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/SealReply.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/SealReply.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/SealReply.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/SealReply.java Thu May 10 22:02:30 2007
@@ -65,7 +65,7 @@
     }
 
 
-    public String getContextKey()
+    protected String getContextKey()
     {
         return ( this.contextKey );
     }

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/TicketGrantingServiceChain.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/TicketGrantingServiceChain.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/TicketGrantingServiceChain.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/kdc/ticketgrant/TicketGrantingServiceChain.java Thu May 10 22:02:30 2007
@@ -40,6 +40,9 @@
     private static final Logger log = LoggerFactory.getLogger( TicketGrantingServiceChain.class );
 
 
+    /**
+     * Creates a new instance of TicketGrantingServiceChain.
+     */
     public TicketGrantingServiceChain()
     {
         if ( log.isDebugEnabled() )

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolCodecFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolCodecFactory.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolCodecFactory.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolCodecFactory.java Thu May 10 22:02:30 2007
@@ -34,6 +34,11 @@
     private static final KerberosProtocolCodecFactory INSTANCE = new KerberosProtocolCodecFactory();
 
 
+    /**
+     * Returns the singleton {@link KerberosProtocolCodecFactory}.
+     *
+     * @return The singleton {@link KerberosProtocolCodecFactory}.
+     */
     public static KerberosProtocolCodecFactory getInstance()
     {
         return INSTANCE;

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolHandler.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolHandler.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/protocol/KerberosProtocolHandler.java Thu May 10 22:02:30 2007
@@ -64,6 +64,12 @@
     private String contextKey = "context";
 
 
+    /**
+     * Creates a new instance of KerberosProtocolHandler.
+     *
+     * @param config
+     * @param store
+     */
     public KerberosProtocolHandler( KdcConfiguration config, PrincipalStore store )
     {
         this.config = config;

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamSubsystem.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamSubsystem.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamSubsystem.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamSubsystem.java Thu May 10 22:02:30 2007
@@ -22,11 +22,13 @@
 
 import java.util.HashMap;
 import java.util.Hashtable;
+import java.util.Map;
 
 import javax.naming.NamingException;
 import javax.naming.directory.DirContext;
 import javax.security.auth.kerberos.KerberosKey;
 
+import org.apache.directory.server.kerberos.shared.messages.value.SamType;
 import org.apache.directory.server.kerberos.shared.store.PrincipalStoreEntry;
 
 
@@ -42,10 +44,11 @@
     /** the property key base used for SAM algorithm verifiers */
     public static final String PROPKEY_BASE = "kerberos.sam.type.";
 
+    /** the SAM subsystem instance */
     public static SamSubsystem instance;
 
     /** a map of verifiers so we do not need to create a new one every time */
-    private final HashMap verifiers = new HashMap();
+    private final Map<SamType, SamVerifier> verifiers = new HashMap<SamType, SamVerifier>();
 
     /** the key integrity checker used by the subsystem for all sam types */
     private KeyIntegrityChecker keyChecker;
@@ -115,7 +118,7 @@
 
         String key = PROPKEY_BASE + entry.getSamType().getOrdinal();
 
-        Hashtable env = new Hashtable();
+        Hashtable<Object, Object> env = new Hashtable<Object, Object>();
 
         try
         {

Modified: directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamVerifier.java
URL: http://svn.apache.org/viewvc/directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamVerifier.java?view=diff&rev=537094&r1=537093&r2=537094
==============================================================================
--- directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamVerifier.java (original)
+++ directory/apacheds/branches/kerberos-encryption-types/protocol-kerberos/src/main/java/org/apache/directory/server/kerberos/sam/SamVerifier.java Thu May 10 22:02:30 2007
@@ -48,11 +48,17 @@
  */
 public interface SamVerifier
 {
-    /** Starts one of many pluggable SAM type subsystem*/
+    /**
+     * Starts one of many pluggable SAM type subsystem.
+     * 
+     * @throws SamException
+     */
     void startup() throws SamException;
 
 
-    /** Shuts down one of many pluggable SAM type subsystem*/
+    /**
+     * Shuts down one of many pluggable SAM type subsystem.
+     */
     void shutdown();
 
 
@@ -62,9 +68,9 @@
      * and supplies it to the verifier to check generated keys to conduct the
      * verification workflow.
      *
-     * @param keyChecker the integrity checker that validates whether or not a
+     * @param keyChecker The integrity checker that validates whether or not a
      * key can decrypt-decode preauth data (an encryped-encoded generalized
-     * timestamp)
+     * timestamp).
      */
     void setIntegrityChecker( KeyIntegrityChecker keyChecker );
 
@@ -72,8 +78,10 @@
     /**
      * Verifies the single use password supplied.
      *
-     * @param principal the kerberos principal to use
-     * @param sad single-use authentication data (encrypted generalized timestamp)
+     * @param principal The kerberos principal to use.
+     * @param sad Single-use authentication data (encrypted generalized timestamp).
+     * @return The {@link KerberosKey}.
+     * @throws SamException 
      */
     KerberosKey verify( KerberosPrincipal principal, byte[] sad ) throws SamException;
 
@@ -81,11 +89,15 @@
     /**
      * Gets the registered SAM algorithm type implemented by this SamVerifier.
      *
-     * @return the type value for the SAM algorithm used to verify the SUP.
+     * @return The type value for the SAM algorithm used to verify the SUP.
      */
     SamType getSamType();
 
 
-    /** sets the user context where users are stored for the primary realm */
+    /**
+     * Sets the user context where users are stored for the primary realm.
+     *  
+     * @param userContext
+     */
     void setUserContext( DirContext userContext );
 }