【发布时间】:2020-04-24 16:17:02
【问题描述】:
在 Windows 7 Professional 系统上,似乎无法运行 New-SelfSignedCertificate。我可以在 Windows 10 系统上。
是的,shell 以“以管理员身份运行”启动。
PS C:\> new-selfsignedcertificate
new-selfsignedcertificate : The term 'new-selfsignedcertificate' is not recognized as the name of a cmdlet,
function, script file, or operable program. Check the spelling of the name, or if a path was included, verify that
the path is correct and try again.
At line:1 char:1
+ new-selfsignedcertificate
+ ~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : ObjectNotFound: (new-selfsignedcertificate:String) [], CommandNotFoundException
+ FullyQualifiedErrorId : CommandNotFoundException
PS C:\> $PSVersionTable.PSVersion
Major Minor Build Revision
----- ----- ----- --------
5 0 10586 117
【问题讨论】:
-
正确。
New-SelfSignedCertificatecmdlet 是 Windows 10 附带的 PKIClient module 的一部分 -
看来对于Windows 7,开发者必须去微软获取
makecert.exe。 -
已确认
New-SelfSignedCertificate在 Windows 8.1 Pro 上运行。我们正在使用它来生成我们的自签名证书。
标签: powershell