Attached is a simple webview in a B4J app, that loads a URL, which tries to establish a SSL connection.
It fails with javax.net.ssl.SSLException: No PSK available. Unable to resume.
The log (at bottom of this post) matches the log in the JDK issue report at JDK-8213202.
I have not yet found a solution.
It occurs in debug and release mode when run from the IDE.
For whatever reason with the attached app, on occasion the exception/trace doesn't appear in the log upon the first LoadURL occurrence. It did at first.
Issue reproduces on a different PC. Both W10, one Home, one Pro.
Using B4J 8.90 and C:\Program Files\Java\jdk-11.0.1\bin\javac.exe
It fails with javax.net.ssl.SSLException: No PSK available. Unable to resume.
The log (at bottom of this post) matches the log in the JDK issue report at JDK-8213202.
I have not yet found a solution.
It occurs in debug and release mode when run from the IDE.
For whatever reason with the attached app, on occasion the exception/trace doesn't appear in the log upon the first LoadURL occurrence. It did at first.
Issue reproduces on a different PC. Both W10, one Home, one Pro.
Using B4J 8.90 and C:\Program Files\Java\jdk-11.0.1\bin\javac.exe
B4X:
Waiting for debugger to connect...
Program started.
May 19, 2021 11:45:15 AM com.sun.webkit.network.URLLoader doRun
WARNING: Unexpected error
javax.net.ssl.SSLException: No PSK available. Unable to resume.
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:129)
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:308)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:264)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:255)
at java.base/sun.security.ssl.ServerHello$T13ServerHelloConsumer.consume(ServerHello.java:1224)
at java.base/sun.security.ssl.ServerHello$ServerHelloConsumer.onServerHello(ServerHello.java:984)
at java.base/sun.security.ssl.ServerHello$ServerHelloConsumer.consume(ServerHello.java:872)
at java.base/sun.security.ssl.SSLHandshake.consume(SSLHandshake.java:392)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:444)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:421)
at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:178)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:164)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1152)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1063)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:402)
at java.base/sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:567)
at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185)
at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(HttpsURLConnectionImpl.java:163)
at javafx.web/com.sun.webkit.network.URLLoader.sendRequest(URLLoader.java:371)
at javafx.web/com.sun.webkit.network.URLLoader.doRun(URLLoader.java:167)
at javafx.web/com.sun.webkit.network.URLLoader.lambda$run$0(URLLoader.java:132)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at javafx.web/com.sun.webkit.network.URLLoader.run(URLLoader.java:131)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)
[note: in this log listing, at this point in time, I had to click on another stock/index such as the DOW at the top of the page to cause the log to 'fill', with a 'duplicate' trace below]
May 19, 2021 11:45:16 AM com.sun.webkit.network.URLLoader doRun
WARNING: Unexpected error
javax.net.ssl.SSLException: No PSK available. Unable to resume.
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:129)
at java.base/sun.security.ssl.Alert.createSSLException(Alert.java:117)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:308)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:264)
at java.base/sun.security.ssl.TransportContext.fatal(TransportContext.java:255)
at java.base/sun.security.ssl.ServerHello$T13ServerHelloConsumer.consume(ServerHello.java:1224)
at java.base/sun.security.ssl.ServerHello$ServerHelloConsumer.onServerHello(ServerHello.java:984)
at java.base/sun.security.ssl.ServerHello$ServerHelloConsumer.consume(ServerHello.java:872)
at java.base/sun.security.ssl.SSLHandshake.consume(SSLHandshake.java:392)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:444)
at java.base/sun.security.ssl.HandshakeContext.dispatch(HandshakeContext.java:421)
at java.base/sun.security.ssl.TransportContext.dispatch(TransportContext.java:178)
at java.base/sun.security.ssl.SSLTransport.decode(SSLTransport.java:164)
at java.base/sun.security.ssl.SSLSocketImpl.decode(SSLSocketImpl.java:1152)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(SSLSocketImpl.java:1063)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(SSLSocketImpl.java:402)
at java.base/sun.net.www.protocol.https.HttpsClient.afterConnect(HttpsClient.java:567)
at java.base/sun.net.www.protocol.https.AbstractDelegateHttpsURLConnection.connect(AbstractDelegateHttpsURLConnection.java:185)
at java.base/sun.net.www.protocol.https.HttpsURLConnectionImpl.connect(HttpsURLConnectionImpl.java:163)
at javafx.web/com.sun.webkit.network.URLLoader.sendRequest(URLLoader.java:371)
at javafx.web/com.sun.webkit.network.URLLoader.doRun(URLLoader.java:167)
at javafx.web/com.sun.webkit.network.URLLoader.lambda$run$0(URLLoader.java:132)
at java.base/java.security.AccessController.doPrivileged(Native Method)
at javafx.web/com.sun.webkit.network.URLLoader.run(URLLoader.java:131)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)