directory-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From erodrig...@apache.org
Subject svn commit: r544722 - in /directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto: checksum/ChecksumHandler.java encryption/CipherTextHandler.java encryption/RandomKeyFactory.java
Date Wed, 06 Jun 2007 04:10:05 GMT
Author: erodriguez
Date: Tue Jun  5 21:10:05 2007
New Revision: 544722

URL: http://svn.apache.org/viewvc?view=rev&rev=544722
Log:
Added root causes to exceptions in kerberos-shared.

Modified:
    directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/checksum/ChecksumHandler.java
    directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/CipherTextHandler.java
    directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/RandomKeyFactory.java

Modified: directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/checksum/ChecksumHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/checksum/ChecksumHandler.java?view=diff&rev=544722&r1=544721&r2=544722
==============================================================================
--- directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/checksum/ChecksumHandler.java
(original)
+++ directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/checksum/ChecksumHandler.java
Tue Jun  5 21:10:05 2007
@@ -105,11 +105,11 @@
         }
         catch ( IllegalAccessException iae )
         {
-            throw new KerberosException( ErrorType.KDC_ERR_SUMTYPE_NOSUPP );
+            throw new KerberosException( ErrorType.KDC_ERR_SUMTYPE_NOSUPP, iae );
         }
         catch ( InstantiationException ie )
         {
-            throw new KerberosException( ErrorType.KDC_ERR_SUMTYPE_NOSUPP );
+            throw new KerberosException( ErrorType.KDC_ERR_SUMTYPE_NOSUPP, ie );
         }
     }
 }

Modified: directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/CipherTextHandler.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/CipherTextHandler.java?view=diff&rev=544722&r1=544721&r2=544722
==============================================================================
--- directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/CipherTextHandler.java
(original)
+++ directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/CipherTextHandler.java
Tue Jun  5 21:10:05 2007
@@ -131,12 +131,11 @@
         }
         catch ( IOException ioe )
         {
-            ioe.printStackTrace();
-            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY );
+            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY, ioe );
         }
         catch ( ClassCastException cce )
         {
-            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY );
+            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY, cce );
         }
     }
 
@@ -160,12 +159,11 @@
         }
         catch ( IOException ioe )
         {
-            ioe.printStackTrace();
-            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY );
+            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY, ioe );
         }
         catch ( ClassCastException cce )
         {
-            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY );
+            throw new KerberosException( ErrorType.KRB_AP_ERR_BAD_INTEGRITY, cce );
         }
     }
 
@@ -265,11 +263,11 @@
         }
         catch ( IllegalAccessException iae )
         {
-            throw new KerberosException( ErrorType.KDC_ERR_ETYPE_NOSUPP );
+            throw new KerberosException( ErrorType.KDC_ERR_ETYPE_NOSUPP, iae );
         }
         catch ( InstantiationException ie )
         {
-            throw new KerberosException( ErrorType.KDC_ERR_ETYPE_NOSUPP );
+            throw new KerberosException( ErrorType.KDC_ERR_ETYPE_NOSUPP, ie );
         }
     }
 }

Modified: directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/RandomKeyFactory.java
URL: http://svn.apache.org/viewvc/directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/RandomKeyFactory.java?view=diff&rev=544722&r1=544721&r2=544722
==============================================================================
--- directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/RandomKeyFactory.java
(original)
+++ directory/apacheds/trunk/kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/crypto/encryption/RandomKeyFactory.java
Tue Jun  5 21:10:05 2007
@@ -81,7 +81,8 @@
      * @return The list of KerberosKey's.
      * @throws KerberosException 
      */
-    public static Map<EncryptionType, EncryptionKey> getRandomKeys( Set<EncryptionType>
ciphers ) throws KerberosException
+    public static Map<EncryptionType, EncryptionKey> getRandomKeys( Set<EncryptionType>
ciphers )
+        throws KerberosException
     {
         Map<EncryptionType, EncryptionKey> map = new HashMap<EncryptionType, EncryptionKey>();
 
@@ -136,7 +137,7 @@
         }
         catch ( NoSuchAlgorithmException nsae )
         {
-            throw new KerberosException( ErrorType.KDC_ERR_ETYPE_NOSUPP, nsae.getMessage()
);
+            throw new KerberosException( ErrorType.KDC_ERR_ETYPE_NOSUPP, nsae );
         }
     }
 }



Mime
View raw message