How can I create a PKCS12 File using OpenSSL (self signed certs)

Solution 1:

I found steps that led to the solution here.

Since the answer is spread out across the question, and the answer, I'll just put exactly what I did below.

Create the key and cert (-nodes creates without password, means no DES encryption [thanks to jewbix.cube for correction])

openssl req -x509 -newkey rsa:4096 -keyout myKey.pem -out cert.pem -days 365 -nodes

Create pkcs12 file

openssl pkcs12 -export -out keyStore.p12 -inkey myKey.pem -in cert.pem