Get the private .key from the .pfx certificate
openssl pkcs12 -in my_certificate.pfx -nocerts -out my_certificate-encrypted.key
Get the decrypted .key file from the encrypted private .key file
openssl rsa -in my_certificate-encrypted.key -out my_certificate.key
Get the .crt file from the .pfx file
openssl pkcs12 -in my_certificate.pfx -clcerts -nokeys -out my_certificate.crt
REF:
https://blog.christian-schou.dk/convert-pfx-to-crt-and-key-file-with-openssl/