Transport Security

patterns & practices Developer Center

  • How to: Use Transport Security
  • How to: Use Secure Conversations in WCF

How to: Use Transport Security

Use the <Security mode> attribute to configure transport security on your binding. The following example shows wsHttpBinding configured to use transport security:

<bindings>
  <wsHttpBinding>
    <binding name="wsHttpEndpointBinding">
      <security mode="Transport">
      </security>
    </binding>
  </wsHttpBinding>
</bindings>

Transport security is available on all of the bindings except for wsDualHttpBinding.

Additional Resources

How to: Use Secure Conversations in WCF

Secure conversations are turned on by default for all bindings that support Web Services Security (WS-Security). This includes wsHttpBinding, netTcpBinding, and netMsmqBinding. If you are using a custom binding, turn on secure conversations with the authenticationMode attribute as follows:

  <customBinding> 
    <binding name="ServiceBinding"> 
      <security authenticationMode="SecureConversation" 
           requireSecurityContextCancellation ="false"> 
         <secureConversationBootstrap authenticationMode="MutualCertificate"> 
         </secureConversationBootstrap> 
      </security> 
      <httpTransport/> 
    </binding> 
   </customBinding>

Additional Resources