これに関するSOに関する投稿は多数あり、私はそれらを精査しましたが、まだ解決策がありません。誰かが私を正しい方向に向けてくれることを願っています。
現在、TLS1.2を使用してリモートプロバイダーに接続する必要があります。そこで、Windows Server 2016をインストールし、必要に応じて構成しました。
リモートサーバーがTLS1.2を実行していて、強調表示された暗号をサポートしていることを知っています。
プロバイダーによって提供されたWSDLによって生成されたC#プロキシクラスを使用してリモートエンドポイントに接続します-エンドをTLS(System.Web.Services.Protocols.SoapHttpClientProtocol)に変換する前に。
When I connect using the proxy I get an exception with the inner exception being "The client and server cannot communicate, because they do not possess a common algorithm".
I cannot see anywhere that ServicePointManager.SecurityProtocol so I am assuming .NET is picking up TLS 1.2 as it is the only enabled protocol? No idea how it is doing the cipher.
Can someone tell me how I go about attempting to fix this? If possible I don't want to regenerate the WSDL proxy class.
If your client application was compiled against .NET Framework 4.5.2 or lower, then by default ServicePointManager.SecurityProtocol is initialized to SecurityProtocolType.Ssl3 | SecurityProtocolType.Tls
(SSL 3.0 and TLS 1.0 only), so it won't be able to connect to a remote server that requires TLS 1.2.
クライアントアプリケーションがTLS1.2を使用できるようにする方法はいくつかあります。
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\
.NETFramework\v4.0.30319
、という名前のDWORD(32ビット)値を追加し、SchUseStrongCrypto
1に設定します(このフラグによりServicePointManager.SecurityProtocol
、に初期化されTls | Tls11 | Tls12
ます。)ServicePointManager.SecurityProtocol |= SecurityProtocolType.Tls12;
プロキシクラスはTLSプロトコルまたは暗号のネゴシエーションを担当しないため、プロキシクラスを再生成する必要はありません。
この記事はインターネットから収集されたものであり、転載の際にはソースを示してください。
侵害の場合は、連絡してください[email protected]
コメントを追加