本文介绍了等效自定义WCF的basicHttpBinding的与TransportWithMessageCredential安全模式结合的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要我的服务器与非WCF客户端集成,并建议更改标题SOAP版本。这可以用&LT完成; textMessageEncoding messageVersion =Soap11/> 在自定义绑定,所以我需要转换的元素我目前的 basicHttpBinding的。我怎样才能做到这一点?

 < basicHttpBinding的>
    <结合>
        <安全模式=TransportWithMessageCredential>
            <交通运输clientCredentialType =的Windows/>
            <消息clientCredentialType =用户名/>
        < /安全>
    < /装订>
< / basicHttpBinding的>
 

解决方案

自定义绑定定义是:

 < customBinding>
  <绑定名称=basicHttpEquivalent>
    <安全authenticationMode =UserNameOverTransport/>
    < textMessageEncoding messageVersion =Soap11/>
    < httpsTransport />
  < /装订>
< / customBinding>
 

但是,这种结合是完全一样的 basicHttpBinding的你提到的。

I need to integrate my server with non-WCF client and suggested to change SOAP version in the headers. This can be done with <textMessageEncoding messageVersion="Soap11" /> element on a custom binding so i need to convert my current basicHttpBinding. How can i do that?

<basicHttpBinding>
    <binding>
        <security mode="TransportWithMessageCredential">
            <transport clientCredentialType="Windows"/>
            <message clientCredentialType="UserName" />
        </security>
    </binding>
</basicHttpBinding>
解决方案

The custom binding definition is:

<customBinding>
  <binding name="basicHttpEquivalent">
    <security authenticationMode="UserNameOverTransport" />
    <textMessageEncoding messageVersion="Soap11" />
    <httpsTransport />
  </binding>
</customBinding>

But this binding is exactly same as the basicHttpBinding you mentioned.

这篇关于等效自定义WCF的basicHttpBinding的与TransportWithMessageCredential安全模式结合的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-10 06:36