Save This Page
Home » openjdk-7 » sun.net.www.protocol » https » [javadoc | source]
sun.net.www.protocol.https
final class: HttpsClient [javadoc | source]
java.lang.Object
   sun.net.NetworkClient
      sun.net.www.http.HttpClient
         sun.net.www.protocol.https.HttpsClient

All Implemented Interfaces:
    HandshakeCompletedListener

This class provides HTTPS client URL support, building on the standard "sun.net.www" HTTP protocol handler. HTTPS is the same protocol as HTTP, but differs in the transport layer which it uses:

System properties used include:

Fields inherited from sun.net.www.http.HttpClient:
cachedHttpClient,  cookieHandler,  requests,  poster,  failedOnce,  httpPortNumber,  proxyDisabled,  usingProxy,  host,  port,  kac,  keepingAlive,  keepAliveConnections,  keepAliveTimeout,  url,  reuse
Fields inherited from sun.net.NetworkClient:
proxy,  serverSocket,  serverOutput,  serverInput,  defaultSoTimeout,  defaultConnectTimeout,  readTimeout,  connectTimeout,  encoding
Constructor:
 HttpsClient(SSLSocketFactory sf,
    URL url,
    String proxyHost,
    int proxyPort) throws IOException 
    Create an HTTPS client URL. Traffic will be tunneled through the specified proxy server.
 HttpsClient(SSLSocketFactory sf,
    URL url,
    Proxy proxy,
    int connectTimeout) throws IOException 
    Same as previous constructor except using a Proxy
 HttpsClient(SSLSocketFactory sf,
    URL url,
    String proxyHost,
    int proxyPort,
    int connectTimeout) throws IOException 
    Create an HTTPS client URL. Traffic will be tunneled through the specified proxy server, with a connect timeout
Method from sun.net.www.protocol.https.HttpsClient Summary:
New,   New,   New,   New,   New,   New,   afterConnect,   closeIdleConnection,   getCipherSuite,   getDefaultPort,   getLocalCertificates,   getLocalPrincipal,   getPeerPrincipal,   getProxyHostUsed,   getProxyPortUsed,   getSSLSocketFactory,   getServerCertificateChain,   getServerCertificates,   handshakeCompleted,   needsTunneling,   putInKeepAliveCache,   setHostnameVerifier,   setSSLSocketFactory
Methods from sun.net.www.http.HttpClient:
New,   New,   New,   New,   New,   New,   afterConnect,   closeIdleConnection,   closeServer,   finalize,   finished,   getCacheRequest,   getDefaultPort,   getHttpKeepAliveSet,   getInputStream,   getKeepAliveTimeout,   getOutputStream,   getProxyHostUsed,   getProxyPortUsed,   getURLFile,   isCachedConnection,   isInKeepAliveCache,   isKeepingAlive,   needsTunneling,   newHttpProxy,   openServer,   openServer,   parseHTTP,   putInKeepAliveCache,   resetProperties,   setCacheRequest,   setDoNotRetry,   setTimeout,   toString,   writeRequests,   writeRequests
Methods from sun.net.NetworkClient:
closeServer,   doConnect,   getConnectTimeout,   getLocalAddress,   getReadTimeout,   openServer,   serverIsOpen,   setConnectTimeout,   setReadTimeout
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from sun.net.www.protocol.https.HttpsClient Detail:
 static HttpClient New(SSLSocketFactory sf,
    URL url,
    HostnameVerifier hv) throws IOException 
 static HttpClient New(SSLSocketFactory sf,
    URL url,
    HostnameVerifier hv,
    boolean useCache) throws IOException 
    See HttpClient for the model for this method.
 static HttpClient New(SSLSocketFactory sf,
    URL url,
    HostnameVerifier hv,
    String proxyHost,
    int proxyPort) throws IOException 
    Get a HTTPS client to the URL. Traffic will be tunneled through the specified proxy server.
 static HttpClient New(SSLSocketFactory sf,
    URL url,
    HostnameVerifier hv,
    String proxyHost,
    int proxyPort,
    boolean useCache) throws IOException 
 static HttpClient New(SSLSocketFactory sf,
    URL url,
    HostnameVerifier hv,
    Proxy p,
    boolean useCache,
    int connectTimeout) throws IOException 
 static HttpClient New(SSLSocketFactory sf,
    URL url,
    HostnameVerifier hv,
    String proxyHost,
    int proxyPort,
    boolean useCache,
    int connectTimeout) throws IOException 
 public  void afterConnect() throws UnknownHostException, IOException 
 public  void closeIdleConnection() 
 String getCipherSuite() 
    Returns the cipher suite in use on this connection.
 protected int getDefaultPort() 
    Returns the default HTTPS port (443)
 public Certificate[] getLocalCertificates() 
    Returns the certificate chain the client sent to the server, or null if the client did not authenticate.
 Principal getLocalPrincipal() 
    Returns the principal the client sent to the server, or null if the client did not authenticate.
 Principal getPeerPrincipal() throws SSLPeerUnverifiedException 
    Returns the principal with which the server authenticated itself, or throw a SSLPeerUnverifiedException if the server did not authenticate.
 public String getProxyHostUsed() 
 public int getProxyPortUsed() 
 SSLSocketFactory getSSLSocketFactory() 
 X509Certificate[] getServerCertificateChain() throws SSLPeerUnverifiedException 
    Returns the X.509 certificate chain with which the server authenticated itself, or null if the server did not authenticate.
 Certificate[] getServerCertificates() throws SSLPeerUnverifiedException 
    Returns the certificate chain with which the server authenticated itself, or throw a SSLPeerUnverifiedException if the server did not authenticate.
 public  void handshakeCompleted(HandshakeCompletedEvent event) 
    This method implements the SSL HandshakeCompleted callback, remembering the resulting session so that it may be queried for the current cipher suite and peer certificates. Servers sometimes re-initiate handshaking, so the session in use on a given connection may change. When sessions change, so may peer identities and cipher suites.
 public boolean needsTunneling() 
 protected  void putInKeepAliveCache() 
  void setHostnameVerifier(HostnameVerifier hv) 
  void setSSLSocketFactory(SSLSocketFactory sf)