代码之家  ›  专栏  ›  技术社区  ›  Afroze Kabeer Khan

Ansible HTTPS连接错误的SSL版本

  •  0
  • Afroze Kabeer Khan  · 技术社区  · 7 年前

    我试图使用credssp使用Ansible连接到我的windows 7计算机,我收到如下错误。

    tls_server_hello,wrong_ssl_version .

    而当我在我的windows 10机器上尝试同样的方法时,我能够做到 win\u ping公司

    2 回复  |  直到 7 年前
        1
  •  0
  •   baduker    6 年前

    我的答案直接来自 Ansible docs. 问题是Windows 7默认使用TLS 1.0,但ansible需要TLS 1.2。

    您可以测试WinRM使用openssl的版本,例如:

    openssl s_client -connect your_win7_remote_host:5986
    
    Protocol displayed has to be TLSv1.2. Follow the steps in link provided to create necessary registry keys and after restart it should work. That is:
    
    Create entry DefaultSecureProtocols with value 0x00000800 (for TLSv1.2 only) or 0x00000A00 (for both TLSv1.1 and TLSv1.2) in keys 
    HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Internet Settings\WinHttp
    
    and (for x64 machines)
    
    HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Internet Settings\WinHttp
    
    Create entry DisabledByDefault with value 0 in key
    HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\SCHANNEL\Protocols\TLS 1.2\Server
    
        2
  •  0
  •   Christopher Alexander Campbell    7 年前

    我也有这个问题,最后来到这里。

    谷歌搜索让我相信这可能是因为windows主机上的第三方根证书可能以某种方式被破坏了。这是一个错误的更新吗?是危险用户吗?谁知道呢!谁在乎呢!

    我做了以下操作,解决了我的连接问题:

    1) 删除 HKEY\U LOCAL\U MACHINE\SOFTWARE\Microsoft\SystemCertificates\AuthRoot\Certificates

    2) 重新启动

    不再出现SSL错误版本错误