Quantcast
Channel: Public Key Infrastructure PowerShell module
Viewing all articles
Browse latest Browse all 729

Commented Unassigned: Running convert-pfxtopem command identical to get-help -examples and failing to work [91]

$
0
0
Hello,

I downloaded then installed pspki module on my Powershell 4.0 then attempted to complete this command and got this result:

PS C:\> $pass = read-host "enter password for pfx file:" -assecurestring
enter password for pfx file:: ***********
PS C:\> convert-pfxtopem -inputpath c:\pki-certs\J140515A4081.pfx -password $pass -outputpath c:\pki-certs\new\J140515A4
081.pem
Convert-PfxToPem : A parameter cannot be found that matches parameter name 'inputpath'.
At line:1 char:18
+ convert-pfxtopem -inputpath c:\pki-certs\J140515A4081.pfx -password $pass -outpu ...
+ ~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Convert-PfxToPem], ParameterBindingException
+ FullyQualifiedErrorId : NamedParameterNotFound,Convert-PfxToPem


Please advise what commands I should use to convert a .pfx to a .pem.

Thanks!

Comments: Yes. The code attempts to export private key and convert it to either, PKCS#1 or PKCS#8 private key format. Actually, the code works only when private key is presented and fails if it is not.

Viewing all articles
Browse latest Browse all 729

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>