I want to generate a self-signed SSL certificate in Windows and use it with my website for IE and Edge.
Two files .pvk
and .cer
needs to be inserted into the code of my website.
I followed this page, run the following commands, generated a powershellcert.pfx
$cert = New-SelfSignedCertificate -certstorelocation cert:\localmachine\my -dnsname company.co.nz
$pwd = ConvertTo-SecureString -String ‘password1234’ -Force -AsPlainText
$path = ‘cert:\localMachine\my\’ + $cert.thumbprint
Export-PfxCertificate -cert $path -FilePath c:\junk\certificate\powershellcert.pfx -Password $pwd
Does anyone know how to generate .pvk
and .cer
?
Edit 1:
I downloaded PVKConverter, and run PVKConverter.exe -i powershellcert -o pvk -d "password1234"
, there is only one file pvk_1.cer
generated.
Does anyone know how I could generate .pvk
as well?