[英]Ansible HTTPS connection wrong SSL version
我嘗試使用credssp使用Ansible連接到Windows 7計算機,並收到以下錯誤。
tls_server_hello,wrong_ssl_version
。
而當我在Windows 10計算機上嘗試相同操作時,我可以執行win_ping
我也遇到了這個問題,並最終到了這里。
谷歌搜索使我相信這可能是因為Windows主機上的第三方根證書可能以某種方式被破壞了。 更新不好嗎? 是危險用戶嗎? 誰知道! 誰在乎!
我做了以下工作,它解決了我的連接問題:
1)刪除HKEY_LOCAL_MACHINE \\ SOFTWARE \\ Microsoft \\ SystemCertificates \\ AuthRoot \\ Certificates
2)重新啟動
沒有更多的SSL錯誤版本錯誤
我的答案直接來自Ansible文檔。 問題是Windows 7默認使用TLS 1.0,但是ansible需要TLS 1.2。
您可以使用openssl測試WinRM使用的版本,例如:
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
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.