c# - WCF 自托管 WebService AddresFilter 不匹配
问题描述
我将工作中的自托管 WebService 迁移到 HTTPS。当我尝试调用方法时出现此错误:
<s:Fault>
<s:Code>
<s:Value>s:Sender</s:Value>
<s:Subcode>
<s:Value>a:DestinationUnreachable</s:Value>
</s:Subcode>
</s:Code>
<s:Reason>
<s:Text xml:lang="it-IT">The message with To '' cannot be processed at the receiver, due to an AddressFilter mismatch at the EndpointDispatcher. Check that the sender and receiver's EndpointAddresses agree.</s:Text>
</s:Reason>
</s:Fault>
这是我的 app.Config:
<system.serviceModel>
<services>
<service name="XWebServiceLib.XWebService" behaviorConfiguration="XWebServiceBehave">
<host>
<baseAddresses>
<add baseAddress="https://xxx.yyy.it/XWebService"/>
</baseAddresses>
</host>
<endpoint address="" binding="wsHttpBinding" bindingConfiguration="MyBinding" contract="XWebServiceLib.IXWebService"/>
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange"/>
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior name="XWebServiceBehave">
<serviceMetadata httpsGetEnabled="true" httpGetEnabled="false" />
<serviceDebug includeExceptionDetailInFaults="true"/>
<dataContractSerializer maxItemsInObjectGraph="2147483647"/>
</behavior>
</serviceBehaviors>
</behaviors>
<bindings>
<wsHttpBinding>
<binding name="MyBinding">
<security mode="Transport">
<transport clientCredentialType="None"/>
</security>
</binding>
</wsHttpBinding>
</bindings>
在迁移到 HTTPS 之前,一切正常……有什么想法吗?
解决方案
推荐阅读
- php - SQL 员工总数
- python - 提交时的 Python 代码返回运行时错误 - NZEC
- r - R 'x' 中的问题必须是原子的”
- arraylist - 使用 Java 8 流将字符串列表分组到自定义对象中
- python - pandas.core.base.DataError:没有数字类型可以在只有数字的数据框中聚合
- gradle - 如何从 Gradle 启动和终止后台进程?
- dialogflow-es - Dialogflow Messenger 未在 UI 中显示丰富的消息,而完整的正常消息显示的是机器人而不是建议芯片
- javascript - 如何在 JavaScript 中定位具有不同类名的兄弟姐妹
- python - 从烧瓶中得到结果
- php - Webmin/Virtualmin - 处理大文件 - 内部服务器错误