Error using SSL with weblogic6.1 using Jsse(ClientCertificateEnforced="true"). ava.net.SocketException: Connection aborted by peer: socket write error
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   Itoyjaved_C
Posted On:   Friday, May 24, 2002 01:44 AM

I'm making a HTTPSURLConnection using Jsse from a java client to weblogic server6.1. I have already kept the CA's certficate of server in TrustedCAFileName. I have already kept the CAcertficate of the server in the keystore of the client. Also I have generated a client certificate using the same CA as my weblogic server(i.e thawte) and stored it in client key store along with the key. When I am using SSL using server authentication only , the code works correctly. But when i am enabling the ClientCertificateEnforced=true , then i am getting socketException connection aborted.. Any idea of solving this problem. Thks    More>>

I'm making a HTTPSURLConnection using Jsse from a java
client to weblogic server6.1.

I have already kept the CA's certficate of server in TrustedCAFileName.

I have already kept the CAcertficate of the server in
the keystore of the client.

Also I have generated a client certificate using the
same CA as my weblogic server(i.e thawte) and stored it
in client key store along with the key.


When I am using SSL using server authentication only ,
the code works correctly. But when i am enabling the
ClientCertificateEnforced=true , then i am getting
socketException connection aborted..

Any idea of solving this problem.


Thks


Following is my code snippet..


char[] passphrase = "changeit".toCharArray();

SSLContext ctx = SSLContext.getInstance("TLS", "SunJSSE");


// KeyStore for the SSL client certificate

KeyStore keyStore = KeyStore.getInstance("JKS");

keyStore.load(new FileInputStream("g:\DEvZHome\keydatabase"), passphrase);

KeyManagerFactory keyManagerFactory = KeyManagerFactory.getInstance("SunX509", "SunJSSE");

keyManagerFactory.init(keyStore, passphrase);


// keyStore for trusted server certs or CAs

KeyStore trustedKeyStore = KeyStore.getInstance("JKS");

trustedKeyStore.load(
new FileInputStream("g:\DEvZHome\keydatabase"), passphrase);

TrustManagerFactory trustManagerFactory = TrustManagerFactory.getInstance("SunX509", "SunJSSE");

trustManagerFactory.init(trustedKeyStore);

ctx.init(keyManagerFactory.getKeyManagers(), trustManagerFactory.getTrustManagers(), null);

SSLSocketFactory sslSocketFactory = ctx.getSocketFactory();

HttpsURLConnection.setDefaultSSLSocketFactory(sslSocketFactory);
   <<Less

Re: Error using SSL with weblogic6.1 using Jsse(ClientCertificateEnforced="true").

Posted By:   belier_belier  
Posted On:   Tuesday, June 4, 2002 06:21 AM


Hello,



I've exactly the same problem : connected in https with httpsurlconnection (jsse) to Weblogic 6.1.
And I've exactely the same exception.
OK without client auth on weblo and KO with client auth on weblo.


Did you resolve it ?


@+

About | Sitemap | Contact