Sachin TrojanGupta wrote:Can I use the following code to create SSLSocket
SSLSocket socket = (SSLSocket) new Socket(IPAddress,port);
Or I have to use the SSLSocketFactory ?
SSLSocketFactory factory = (SSLSocketFactory)SSLSocketFactory.getDefault();
SSLSocket socket = (SSLSocket)factory.createSocket(IPAddress,port);
Is there any difference in socket if created by different methods. If yes, then which is the preferred way to create a SSLSocket.