Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    primarykey
    data
    text
    <p>Extend <code>JEditorPane</code> to override the <a href="http://java.sun.com/javase/6/docs/api/javax/swing/JEditorPane.html#getStream(java.net.URL)" rel="noreferrer"><code>getStream()</code></a> method.</p> <p>Inside that method, you can <a href="http://java.sun.com/javase/6/docs/api/java/net/URL.html#openConnection()" rel="noreferrer">open a <code>URLConnection</code>.</a> Test whether it is an <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/HttpsURLConnection.html" rel="noreferrer"><code>HttpsURLConnection</code></a>. If it is, <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/SSLContext.html#init(javax.net.ssl.KeyManager[],%20javax.net.ssl.TrustManager[],%20java.security.SecureRandom)" rel="noreferrer">initialize</a> your <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/SSLContext.html#getInstance(java.lang.String)" rel="noreferrer">own <code>SSLContext</code></a> with a custom <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/X509TrustManager.html" rel="noreferrer"><code>X509TrustManager</code></a> that doesn't perform any <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/X509TrustManager.html#checkServerTrusted(java.security.cert.X509Certificate[],%20java.lang.String)" rel="noreferrer">checks.</a> <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/HttpsURLConnection.html#getSSLSocketFactory()" rel="noreferrer">Get the context's <code>SSLSocketFactory</code></a> and <a href="http://java.sun.com/javase/6/docs/api/javax/net/ssl/HttpsURLConnection.html#setSSLSocketFactory(javax.net.ssl.SSLSocketFactory)" rel="noreferrer">set it as the socket factory</a> for the connection. Then return the <code>InputStream</code> <a href="http://java.sun.com/javase/6/docs/api/java/net/URLConnection.html#getInputStream()" rel="noreferrer">from the connection.</a></p> <p>This will defeat any attempts by the runtime to protect the user from a spoof site serving up malware. If that's <em>really</em> what you want&hellip;</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. VO
      singulars
      1. This table or related slice is empty.
    2. VO
      singulars
      1. This table or related slice is empty.
    3. VO
      singulars
      1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload