I have a .pem file and a .pub file, I used following commands to create them
openssl genrsa -out temp.pem 1024
openssl rsa -in temp.pem -pubout -out temp.pub
Now I want to make them to a one .pfx file which is binary and contains both private and public key. Is it possible? how? (I have tested som openssl commands but the file was empty).
I used this command
openssl pkcs12 -export -in temp.pem -inkey temp.pub -out temp.pfx -name "Temp Certificate"
it generates this error:
unable to load private key 17880:error:0906D06C:PEM routines:PEM_read_bio:no start line:.\crypto\pem\pem_li b.c:703:Expecting: ANY PRIVATE KEY