Openssl < 3 :

openssl pkcs12 -in star_site_net.pfx -clcerts -nodes  -out star_site_net.pem

openssl pkcs12 -in star_site_net.pfx -nocerts -nodes -out star_site_net.key

Openssl > 3 :

openssl pkcs12 -in star_site_net.pfx -clcerts -nodes -provider legacy -provider default -out star_site_net.pem

openssl pkcs12 -in star_site_net.pfx -nocerts -nodes -provider legacy -provider default -out star_site_net.key

 

Links:

https://www.entrust.com/knowledgebase/ssl/how-do-i-convert-a-pfx-to-be-used-with-an-apache-server

https://stackoverflow.com/questions/72598983/curl-openssl-error-error0308010cdigital-envelope-routinesunsupported