<scopedCertificates> 要素の <add>

範囲指定された証明書のコレクションに X.509 証明書を追加します。

スキーマの階層

<system.serviceModel>
  <behaviors>
    <endpointBehaviors>
      <endpointBehaviors> の <behavior>
        <clientCredentials>
          <serviceCredentials> の <serviceCertificate>
            <scopedCertificates> 要素
              <scopedCertificates> 要素の <add>

構文

<add findValue="String"
          storeLocation="CurrentUser/LocalMachine"
          storeName=" CurrentUser/LocalMachine"
          targetUri="string"
         x509Type="FindByThumbprint/FindBySubjectName/FindBySubjectDistinguishedName/FindByIssuerName/FindByIssuerDistinguishedName/FindBySerialNumber/FindByTimeValid/FindByTimeNotYetValid/FindBySerialNumber/FindByTimeExpired/FindByTemplateName/FindByApplicationPolicy/FindByCertificatePolicy/FindByExtension/FindByKeyUsage/FindBySubjectKeyIdentifier" 
/> 

属性と要素

以降のセクションでは、属性、子要素、および親要素について説明します。

属性

属性 説明

targetUri

文字列です。証明書に関連付けられているサービスの URI を指定します。

findValue

文字列です。検索対象の値。

x509FindType

列挙値です。検索する証明書フィールドのいずれかです。

storeLocation

列挙値です。検索する 2 つの格納場所のいずれかです。

storeName

列挙値です。検索するシステム ストアのいずれかです。

子要素

なし。

親要素

要素 説明

<scopedCertificates> 要素

認証用の (範囲指定された) 特定のサービスにより提供される X.509 証明書のコレクションを表します。

解説

この要素を使用すると、クライアントは、通信するサービスの URL に基づいて、使用するサービス証明書を構成できます。これは、クライアントが複数のサービス (エンド サービスと中間セキュリティ トークン サービス) と通信している可能性がある発行済みトークンのシナリオで特に便利です。証明書に基づくメッセージ セキュリティを使用したバインドにおいて、この証明書を使用してサービスへのメッセージを暗号化します。サービスがクライアントへの応答に署名する際には、この証明書を使用することが要求されます。

バインディングにサービスの証明書が必要で、サービスの URL に対する特定の証明書が ScopedCertificates 内に存在しない場合は、既定の証明書が使用されます。

詳細については、「How To: Create a Federated Client」の「範囲指定された証明書」セクションを参照してください。

次の例は、コレクションに X.509 証明書を追加します。

<behaviors>
 <endpointBehaviors>
  <behavior name="MyEndpointBehavior">
   <clientCredentials>
    <serviceCertificate>
     <scopedCertificates>
      <add targetUri="https://www.contoso.com" 
       findValue="www.Contoso.com" 
       storeLocation="LocalMachine"
       storeName="Root" 
       x509FindType="FindByIssuerName" />
     </scopedCertificates>
    </serviceCertificate>
   </clientCredentials>
  </behavior>
 </endpointBehaviors>
</behaviors>

参照

リファレンス

ScopedCertificates
X509ScopedServiceCertificateElementCollection
X509ScopedServiceCertificateElement
X509CertificateRecipientClientCredential
ScopedCertificates

その他のリソース

How To: Create a Federated Client
Working with Certificates
Securing Clients
Securing Services and Clients