SslCertificateTrust.CreateForX509Collection メソッド
定義
重要
一部の情報は、リリース前に大きく変更される可能性があるプレリリースされた製品に関するものです。 Microsoft は、ここに記載されている情報について、明示または黙示を問わず、一切保証しません。
新しい SslCertificateTrustを作成します。
public static System.Net.Security.SslCertificateTrust CreateForX509Collection(System.Security.Cryptography.X509Certificates.X509Certificate2Collection trustList, bool sendTrustInHandshake = false);
[System.Runtime.Versioning.UnsupportedOSPlatform("windows")]
public static System.Net.Security.SslCertificateTrust CreateForX509Collection(System.Security.Cryptography.X509Certificates.X509Certificate2Collection trustList, bool sendTrustInHandshake = false);
static member CreateForX509Collection : System.Security.Cryptography.X509Certificates.X509Certificate2Collection * bool -> System.Net.Security.SslCertificateTrust
[<System.Runtime.Versioning.UnsupportedOSPlatform("windows")>]
static member CreateForX509Collection : System.Security.Cryptography.X509Certificates.X509Certificate2Collection * bool -> System.Net.Security.SslCertificateTrust
Public Shared Function CreateForX509Collection (trustList As X509Certificate2Collection, Optional sendTrustInHandshake As Boolean = false) As SslCertificateTrust
パラメーター
- trustList
- X509Certificate2Collection
信頼された証明書を含むコレクション。
- sendTrustInHandshake
- Boolean
true TLS ハンドシェイク中にサーバーが信頼された証明機関の一覧を送信する場合。リストを送信しない false 。
戻り値
信頼ポリシーを表します。
- 属性
例外
sendTrustInHandshake は true であり、現在のプラットフォームはハンドシェイクでの信頼された発行者リストの送信をサポートしていません。
注釈
sendTrustInHandshake引数がtrueされている場合、クライアントはサーバーからの信頼された証明機関の一覧を使用して、適切なクライアント証明書を選択できます。 信頼された発行者リストの送信は、.NET 6 の SslCertificaetTrust.CreateForX509Collection を使用して作成された SslCertificateTrust インスタンスではサポートされていません。
.NET 7 以降、送信側の信頼された発行者の一覧は、Linux および OSX プラットフォームでサポートされています。
Warning
信頼できる CA の一覧により、ハンドシェイク メッセージのサイズが大きくなります。 また、システムの構成に関する情報漏えいと見なすこともできます。 このような理由から、 sendTrustInHandshake を false に設定することをお勧めします。