code: public SSLSocket getSSLSocket() throws KeystoreException, CommunicationException {
  		SSLSocketFactory socketFactory = getSSLSocketFactory();
  		logger.debug("Creating SSLSocket to " + getServerHost() + ":" + getServerPort());
  
  		try {
  			if (ProxyManager.isUsingProxy(server)) {
  				return tunnelThroughProxy(socketFactory);
  			} else {
  				return (SSLSocket) socketFactory.createSocket(getServerHost(), getServerPort());
  			}
  		} catch (Exception e) {
  			throw new CommunicationException("Communication exception: " + e, e);
  		}
  	}
docs: Create a SSLSocket which will be used to send data to Apple
  @return the SSLSocket
  @throws KeystoreException
  @throws CommunicationException