code: public SSLSocket newSslSocket() throws IOException {
          SSLSocketFactory factory = sslContext.getSocketFactory();
          
          SSLSocket socket = (SSLSocket)factory.createSocket();
          
          if (sslConfig.getWantClientAuth())
              socket.setWantClientAuth(sslConfig.getWantClientAuth());
          if (sslConfig.getNeedClientAuth())
              socket.setNeedClientAuth(sslConfig.getNeedClientAuth());
  
          socket.setEnabledCipherSuites(selectCipherSuites(socket.getEnabledCipherSuites(),
  							 socket.getSupportedCipherSuites()));   
          socket.setEnabledProtocols(selectProtocols(socket.getEnabledProtocols(),socket.getSupportedProtocols()));
  
          return socket;
      }
docs: Get an SSLSocket from this context.
  {@link SSLContext#getSocketFactory()}