- Create a key
openssl genrsa -out key.pem 2048- Create certificate sign-in request
openssl req -new -sha256 -key key.pem -out csr.csrEnter whatever information you wish
- Create certificate
openssl req -x509 -sha256 -days 365 -key key.pem -in csr.csr -out certificate.pem- Convert to .pfx file
openssl pkcs12 -export -inkey key.pem -in certificate.pem -out certificate.pfx