SSL: Difference between revisions
Jump to navigation
Jump to search
Line 6: | Line 6: | ||
<source lang=bash> |
<source lang=bash> |
||
# Strangely we cannot pipe output of 1st command into 2nd (error 'No certificate matches private key') |
# Strangely we cannot pipe output of 1st command into 2nd (error 'No certificate matches private key') |
||
openssl pkcs12 -in mycert.pfx out mycert.pem -nodes # Don't encrypt private key at all |
openssl pkcs12 -in mycert.pfx -out mycert.pem -nodes # Don't encrypt private key at all |
||
openssl pkcs12 -export -in mycert.pem -out mycert-new.pfx |
openssl pkcs12 -export -in mycert.pem -out mycert-new.pfx |
||
rm mycert.pem # DON'T FORGET THIS! |
rm mycert.pem # DON'T FORGET THIS! |
Revision as of 10:51, 29 October 2012
Checking Certificate Chain with OpenSSL
Checking A Remote Certificate Chain With OpenSSL
Change .p12 / .pfx password
Say you have a private key / certificate file mycert.pfx, and you want to change its password:
# Strangely we cannot pipe output of 1st command into 2nd (error 'No certificate matches private key')
openssl pkcs12 -in mycert.pfx -out mycert.pem -nodes # Don't encrypt private key at all
openssl pkcs12 -export -in mycert.pem -out mycert-new.pfx
rm mycert.pem # DON'T FORGET THIS!