在PowerShell和Server 2012 R2中使用Get-TlsCipherSuite

egdjgwm8  于 2022-11-10  发布在  Shell
关注(0)|答案(3)|浏览(338)

我的PowerShell TLS模块似乎不包含cmdlet Get-TlsCipherSuite

PS>**(Get-Module tls).ExportedCommands**

Key                         Value
---                         -----
Disable-TlsSessionTicketKey Disable-TlsSessionTicketKey
Enable-TlsSessionTicketKey  Enable-TlsSessionTicketKey
Export-TlsSessionTicketKey  Export-TlsSessionTicketKey
New-TlsSessionTicketKey     New-TlsSessionTicketKey

但我不确定如何才能更新它。
我在PS 5.1上

Major  Minor  Build  Revision
-----  -----  -----  --------
5      1      14409  1018

我曾尝试过

PS>**Update-Module tls**
Update-Module : Module 'tls' was not installed by using Install-Module, so it
cannot be updated.
  • 编辑:*

我认为这是Server 2012和R2的限制,因为该cmdlet未在此处的2012中列出
https://learn.microsoft.com/en-us/powershell/module/tls/?view=win10-ps
然而,它被列为2016年。有没有办法将此命令导入2012年的R2?

owfi6suc

owfi6suc1#

根据documentation,Windows Server 2012中的TLS模块R2没有您要找的cmdlet。据我所知,如果不升级到更新的Windows版本,您将无法更新模块。

kupeojn6

kupeojn62#

Get-ItemPropertyValue -Path HKLM:\SYSTEM\CurrentControlSet\Control\Cryptography\Configuration\Local\SSL\00010002 -Name Functions
h43kikqp

h43kikqp3#

Arjun的回答是正确的,但它使用的是Get-ItemPropertyValue cmdlet,该cmdlet本身是为以后的PowerShell版本保留的。完全兼容PowerShell 2.0的Get-TLSCipherSuite命令版本如下:

(get-itemproperty HKLM:\SYSTEM\CurrentControlSet\Control\Cryptography\Configuration\Local\SSL\00010002 -Name Functions).Functions

相关问题