Question

I have obtained a certificate by a trusted authority (have been given a .pfx file).

I signed all my .jar files with jarsigner like this:

jarsigner -storetype pkcs12 -keystore my_pfx_file.pfx -storepass my_store_pwd -signedjar Smy_jar.jar my_jar.jar

Then I exported the certificate from the keystore to create a .cer file.

What else do I have to do so that I don't get the message from "Unknown Publisher" and instead has the Company name?

Was it helpful?

Solution

I figured it out. It was a problem with the .pfx file. I could see the certificate chain in the mmc console, but when I used:
keytool -list -storetype pkcs12 -keystore my_pfx_file.pfx,
I saw the certificate chain length was 1.
So I exported the certificate from the mmc console. Only this time, I check the box that says "Include all certificates in the certification path if possible". I got a new .pfx file with which I signed my jars and it works perfectly.
This post helped me a lot to figure out what was going on: How to sign java applet with .pfx file?

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top