I’d like to ask the question about the exporting a certificate using openssl command. In essence, I have to export the certificate and import it to MS Exchange server and this job should be automated as a regular job such as cron.
So, exporting certificate was actually fine, it had no problems. I ran the following commands to do so.
openssl pkcs12 -export -out /tmp/cert.pfx -inkey privkey.pem -in cert.pem -certfile chain.pem -passout pass:
Now, when I typed the following command for verification, the system asked a PEM pass phrase.
openssl pkcs12 -in /tmp/cert.pfx -info
[ Output truncated ]
Shrouded Keybag: pbeWithSHA1And3-KeyTripleDES-CBC, Iteration 2048
localKeyID: E5 1F EC A9 59 09 82 45 29 90 02 CB C6 43 38 E0 88 1E A5 78
Enter PEM pass phrase:
Of course, I don’t know what that means so I just pressed Enter key and the following happened.
Error outputting keys and certificates
140271773574400:error:28069065:UI routines:UI_set_result:result too small:…/crypto/ui/ui_lib.c:778:You must type in 4 to 1024 characters
140271773574400:error:2807106B:UI routines:UI_process:processing error:…/crypto/ui/ui_lib.c:493:while reading strings
140271773574400:error:0906406D:PEM routines:PEM_def_callback:problems getting password:…/crypto/pem/pem_lib.c:64:
140271773574400:error:0907E06F:PEM routines:do_pk8pkey:read key:…/crypto/pem/pem_pk8.c:83:
In my opinion, it looks like the system is asking a passphrase for private key. However, I don’t have that. The system used the following command to get the certificate.
certbot --nginx -n --agree-tos --email systems@mydomain --redirect --domains mail.mydomain
Can someone please explain what this is about and how to resolve it? I would really appreciate it if anyone can help me. Thanks a lot.