The Example commands provided require the openSSL libraries and tools.
If OpenSSL is not on your platform you can obtain the source.
Some documentation is available.
Converting Certificate Formats is often part of a Data Extraction Transformation process.
You can use some of the online SSL Converters to convert certificates without messing with OpenSSL.
openssl x509 -inform der -in certificate.cer -out certificate.pem
openssl x509 -outform der -in certificate.pem -out certificate.der
openssl pkcs12 -in keyStore.pfx -out keyStore.pem -nodes
You can add -nocerts to only output the private key or add -nokeys to only output the certificates.
openssl pkcs12 -export -out certificate.pfx -inkey privateKey.key -in certificate.crt -certfile CACert.crt