dcsimg
"com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake([DashoPro-V1.2-120198])" Exception
0 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   swapnil_gorantiwar
Posted On:   Wednesday, July 10, 2002 11:23 PM

Hi, I am trying to estabilish a scoket connection to a secyred site(https) thru proxy server.But I am getting the error here is the piece of code which I am using while making socket connection *********************************************************** Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider()); SSLSocketFactory factory = (SSLSocketFactory)SSLSocketFactory.getDefault(); System.setProperty("java.protocol.handler.pkgs","com.sun.net.ssl.internal.www.protocol"); InetAddress addr = InetAddress.getByName(siteName); SSLSocket sslSocket = (SSLSocket)factory.createSocket(addr, 443); sslSocket.startHandshake(); *************************   More>>

Hi,
I am trying to estabilish a scoket connection to a secyred site(https) thru proxy server.But I am getting the error here is the piece of code which I am using while making socket connection



***********************************************************

Security.addProvider(new com.sun.net.ssl.internal.ssl.Provider());
SSLSocketFactory factory = (SSLSocketFactory)SSLSocketFactory.getDefault();
System.setProperty("java.protocol.handler.pkgs","com.sun.net.ssl.internal.www.protocol");
InetAddress addr = InetAddress.getByName(siteName);
SSLSocket sslSocket = (SSLSocket)factory.createSocket(addr, 443);
sslSocket.startHandshake();

**********************************************************
where "siteName" is the URL. e.g (https://www.versign.com")


this is the error which I am getting while Handshaking
***********************************************************

"java.net.SocketException: Socket closed
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.a([DashoPro-V1.2-120198])
at com.sun.net.ssl.internal.ssl.AppOutputStream.write([DashoPro-V1.2-120198])
at java.io.OutputStream.write(OutputStream.java:61)
at com.sun.net.ssl.internal.ssl.SSLSocketImpl.startHandshake([DashoPro-V1.2-120198])
at com.ezdata.das.dascomponent.requestprocessor.UrlSimulator.handleProxy(UrlSimulator.java:349)
at com.ezdata.das.dascomponent.requestprocessor.UrlSimulator.doRequest(UrlSimulator.java:480)
at com.ezdata.das.dascomponent.requestprocessor.UrlSimulator.run(UrlSimulator.java:518)
at java.lang.Thread.run(Thread.java:484)"

Hoping for the early reply
Regards
Swapnil

   <<Less
About | Sitemap | Contact