Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
menu search
person
Welcome To Ask or Share your Answers For Others

Categories

As BasicHttpsBinding is new at .net 4.5, I don't seem to be able to find much stuff around differences between the two.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
761 views
Welcome To Ask or Share your Answers For Others

1 Answer

Indeed the two bindings are very similar. The only real difference is that to require HTTPS, the endpoint needed to be configured with a BasicHttpBinding in which you define the security mode as Transport (or any of the other valid enumerations). With a BasicHttpsBinding on the endpoint, the security mode is defaulted to Transport and the client credential type is set to None.

So here was your configuration before WCF 4.5:

<system.serviceModel>
  <bindings>
    <basicHttpBinding>
      <binding name="Service.BasicHttp.BindingConfig">
        <security mode="Transport" />        
      </binding>
    </basicHttpBinding>
  </bindings>
  <services>
    <service name="ServiceImpl">
      <endpoint address="" binding="basicHttpBinding" bindingConfiguration="Service.BasicHttp.BindingConfig"
                name="IService.Http" contract="IService">
      </endpoint>
    </service>
  </services>
</system.serviceModel>

With WCF 4.5, the same configuration can be simplified to:

<system.serviceModel>
  <services>
    <service name="ServiceImpl">
      <endpoint address="" binding="basicHttpsBinding" name="IService.Http" contract="IService">
  </endpoint>
</service>
  </services>
</system.serviceModel>

See What’s new in WCF 4.5? BasicHttpsBinding for additional detail.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
thumb_up_alt 0 like thumb_down_alt 0 dislike
Welcome to ShenZhenJia Knowledge Sharing Community for programmer and developer-Open, Learning and Share
...