I have created a Keystore and imported my certificate (issued by an official CA) into it using keytool, no problems there.
Next, I start up Jetty (v. 8.0.0 M3) and give it the location of the keystore using the -DjettySslKeyStoreFile parameter, Jetty starts up fine, runs on port 443 too.
When I go to https://site.com however, the certificate I get is invalid. When examining the certificate, it seems Jetty forwards the information I entered when generating the keystore (using keytool -genkey), instead of the information contained in the certificate itself.
What do I need to do so that Jetty sends the certificate found inside the keystore, instead of the data stored in the keystore? I wasn’t able to find any documentation on this. I would expect that you’d give the certificate a specific alias when inserting it into the keystore, or that you can configure what alias Jetty should serve.
We never actually figured this out. Instead, we went for an nginx SSL proxy in front of it, which – functionally – works just as well, and with this we get support and setup from our hosting party as well.