kaikramer / keystore-explorer

KeyStore Explorer is a free GUI replacement for the Java command-line utilities keytool and jarsigner.
https://keystore-explorer.org/
GNU General Public License v3.0
1.7k stars 275 forks source link

Output signed certificate #181

Closed mouse07410 closed 2 years ago

mouse07410 commented 5 years ago

Is your feature request related to a problem? This is about KSE signing a Certificate Signing Request (CSR). The problem is that none of the software I'm using (OpenSSL, OpenSC, Java) deals gracefully with what KSE outputs for "Sign CSR".

Applications typically expect a CA to intake a CSR and return a "real" certificate, in DER or PEM. KSE, however, returns a DER-encoded PKCS#7 file that contains a set of certificates, including the one requested.

It may be fine on Windows (I don't know, as I don't use it), but on Linux and Mac it creates a big problem - no software can use that response. I have to print the content of the returned PKCS#7 file, and manually edit it to extract the produced certificate.

Describe the solution you'd like KSE should offer a choice between outputting

Describe alternatives you've considered The only alternative I found so far is

$ openssl pkcs7 -inform DER -in <your_output.p7r> -print_certs > certs.txt
$ vi certs.txt
[ remove the dross, write the certificate in PEM format into a new file, like cert.pem]
kaikramer commented 5 years ago

I have encountered many "real" CAs that return PKCS#7 format, but I agree, there should be a choice.

mouse07410 commented 5 years ago

I agree, there should be a choice

Thank you! Especially since there is no tool that would extract the requested cert from the PKCS#7 file (I don't consider hacking the file manually with vi or such as a "tool").

kaikramer commented 2 years ago

Closing tickets in preparation for release of KSE 5.5.0