harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From hinde...@apache.org
Subject svn commit: r982146 - in /harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth: internal/nls/messages.properties module/KeyStoreLoginModule.java
Date Wed, 04 Aug 2010 07:47:43 GMT
Author: hindessm
Date: Wed Aug  4 07:47:43 2010
New Revision: 982146

URL: http://svn.apache.org/viewvc?rev=982146&view=rev
Log:
Apply patch from "[#HARMONY-6599] [classlib][auth] added extra nls to
auth/src/main/java/common/org/apache/harmony/module/keystorloginmodule.java
package".

Modified:
    harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/internal/nls/messages.properties
    harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/module/KeyStoreLoginModule.java

Modified: harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/internal/nls/messages.properties
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/internal/nls/messages.properties?rev=982146&r1=982145&r2=982146&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/internal/nls/messages.properties
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/internal/nls/messages.properties
Wed Aug  4 07:47:43 2010
@@ -117,3 +117,5 @@ auth.62=Protected authentication path mu
 auth.63=Failure to get KeyStore or KeyStore Password
 auth.64=KerberosErrorMessage encoder is not implemented
 auth.65=Not implemented
+auth.66=Cannot find certificate path for {0}
+auth.67=Cannot find private key for {0}

Modified: harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/module/KeyStoreLoginModule.java
URL: http://svn.apache.org/viewvc/harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/module/KeyStoreLoginModule.java?rev=982146&r1=982145&r2=982146&view=diff
==============================================================================
--- harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/module/KeyStoreLoginModule.java
(original)
+++ harmony/enhanced/java/trunk/classlib/modules/auth/src/main/java/common/org/apache/harmony/auth/module/KeyStoreLoginModule.java
Wed Aug  4 07:47:43 2010
@@ -294,9 +294,9 @@ public class KeyStoreLoginModule impleme
             Certificate[] certificates = keyStore
                     .getCertificateChain(keyStoreAlias);
             if (null == certificates || certificates.length == 0) {
-                throw new FailedLoginException(
-                        "Cannot find certificate path for " + keyStoreAlias);
-            }
+                //auth.66=Cannot find certificate path for {0}
+                throw new FailedLoginException(Messages.getString("auth.66", keyStoreAlias));
//$NON-NLS-1$
+                }
             List<Certificate> list = new ArrayList<Certificate>(
                     certificates.length);
             for (int i = 0; i < certificates.length; i++) {
@@ -312,9 +312,9 @@ public class KeyStoreLoginModule impleme
 
             Key privateKey = keyStore.getKey(keyStoreAlias, privateKeyPassword);
             if (null == privateKey || !(privateKey instanceof PrivateKey)) {
-                throw new FailedLoginException("Cannot find private key for "
-                        + keyStoreAlias);
-            }
+                //auth.67=Cannot find private key for {0}
+                throw new FailedLoginException(Messages.getString("auth.67", keyStoreAlias));
//$NON-NLS-1$
+               }
             privateCredential = new X500PrivateCredential(firstCertificate,
                     (PrivateKey) privateKey, keyStoreAlias);
 



Mime
View raw message