https://linen.dev logo
Title
w

William Laing

01/25/2023, 9:09 PM
How can I resolve my ssl certificate not being recognized by the browser? I have added a keystore jks file but the browser doesnt like the certificate?
t

Tom

01/25/2023, 9:10 PM
You can download the PEM version, which your browser should accept
w

William Laing

01/25/2023, 9:15 PM
Failed to export certificate authority cert from /Users/..../.wiremock/ca-keystore.jks
t

Tom

01/25/2023, 9:16 PM
Are you running Java 17+?
w

William Laing

01/25/2023, 9:16 PM
openjdk version "19.0.1" 2022-10-18 OpenJDK Runtime Environment (build 19.0.1+10-21) OpenJDK 64-Bit Server VM (build 19.0.1+10-21, mixed mode, sharing)
Am i running the wrong version of java?
t

Tom

01/25/2023, 9:17 PM
For 17+ you need to start the server with an arg that allows the sun crypto libraries to be included:
--add-exports=java.base/sun.security.x509=ALL-UNNAMED
w

William Laing

01/25/2023, 9:19 PM
Exception in thread "main" joptsimple.UnrecognizedOptionException: add-exports is not a recognized option
java -jar wiremock-jre8-standalone-2.35.0.jar --https-port 8443 --https-keystore ./keystore.jks --add-exports=java.base/sun.security.x509=ALL-UNNAMED --verbose
t

Tom

01/25/2023, 9:19 PM
I think you need to add it before the
-jar
part
1
w

William Laing

01/25/2023, 9:22 PM
hmmm still same issue
Failed to export certificate authority cert from
thanks for the help @Tom I keep trying tomorrow.