public static Socket createSsl(Socket socket) throws IOException {
SSLSocketFactory factory = (SSLSocketFactory) SSLSocketFactory.getDefault();
SSLSocket sslsocket = (SSLSocket) (factory.createSocket(socket, socket
.getInetAddress().getHostAddress(), socket.getPort(), true));
sslsocket.setUseClientMode(false);
sslsocket.startHandshake();
return sslsocket;
}
当 sslsocket.startHandshake() 时 sslsocket 总是读取超时,那么我应该怎么做才能解决这个问题呢?