B4J Question [SOLVED] Packager problem (SSL doesn't work)

rosippc64a

Active Member
Licensed User
Longtime User
Hi All!
I have a big project what need doing SSL connection. On my development machine (win 10 home) the program works well. When I make a package (project -> make a standalone package) and install it into a fresh installed win 10 home (no any preinstalled java), the program can run, but no SSL connection.
In my project I use the "#AdditionalJar: bcprov-jdk14-1.64.jar" and use the c:\java\jdk-11.0.1\bin\javac.exe for compiling. I am using the accept all option also.
The error result is:
(Http client initialized with accept all option.)
javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
at java.base/sun.security.ssl.Alert.createSSLException(Unknown Source)
at java.base/sun.security.ssl.Alert.createSSLException(Unknown Source)
at java.base/sun.security.ssl.TransportContext.fatal(Unknown Source)
at java.base/sun.security.ssl.Alert$AlertConsumer.consume(Unknown Source)
at java.base/sun.security.ssl.TransportContext.dispatch(Unknown Source)
at java.base/sun.security.ssl.SSLTransport.decode(Unknown Source)
at java.base/sun.security.ssl.SSLSocketImpl.decode(Unknown Source)
at java.base/sun.security.ssl.SSLSocketImpl.readHandshakeRecord(Unknown Source)
at java.base/sun.security.ssl.SSLSocketImpl.startHandshake(Unknown Source)
at b4j/okhttp3.internal.connection.RealConnection.connectTls(Unknown Source)
at b4j/okhttp3.internal.connection.RealConnection.establishProtocol(Unknown Source)
at b4j/okhttp3.internal.connection.RealConnection.buildConnection(Unknown Source)
at b4j/okhttp3.internal.connection.RealConnection.connect(Unknown Source)
at b4j/okhttp3.internal.connection.StreamAllocation.findConnection(Unknown Source)
at b4j/okhttp3.internal.connection.StreamAllocation.findHealthyConnection(Unknown Source)
at b4j/okhttp3.internal.connection.StreamAllocation.newStream(Unknown Source)
at b4j/okhttp3.internal.connection.ConnectInterceptor.intercept(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.internal.cache.CacheInterceptor.intercept(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.internal.http.BridgeInterceptor.intercept(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.internal.http.RetryAndFollowUpInterceptor.intercept(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.internal.http.RealInterceptorChain.proceed(Unknown Source)
at b4j/okhttp3.RealCall.getResponseWithInterceptorChain(Unknown Source)
at b4j/okhttp3.RealCall.execute(Unknown Source)
at b4j/anywheresoftware.b4h.okhttp.OkHttpClientWrapper.executeWithTimeout(Unknown Source)
at b4j/anywheresoftware.b4h.okhttp.OkHttpClientWrapper.access$0(Unknown Source)
at b4j/anywheresoftware.b4h.okhttp.OkHttpClientWrapper$ExecuteHelper.run(Unknown Source)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
at java.base/java.util.concurrent.FutureTask.run(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
at java.base/java.lang.Thread.run(Unknown Source)
Suppressed: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure
... 37 more
ResponseError. Reason: javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure, Response:
JobName = QueryTransactionStatusRequest, Success = false
Is it enough to tell me what jar or somewhat else do I need to put into the package to get rid this error?
 

rosippc64a

Active Member
Licensed User
Longtime User
I should read...

I need put jdk.crypto.ec into my project (as @Erel said)
B4X:
#PackagerProperty: IncludedModules = jdk.charsets, javafx.web, jdk.crypto.ec
 
Upvote 0
Top