WCF和SSL的问题
我在使用SSL和WCF使web服务工作时遇到问题 如果我在“需要SSL”页面中签入IIS,则会出现以下错误: WebHost无法处理请求 发件人信息: System.ServiceModel.ServiceHostingEnvironment+HostingManager/36097441 异常:System.ServiceModel.ServiceActivationException:服务 由于编译期间出现异常,无法激活“/”。这个 异常消息是:服务 “ISS.MS.WebServices.MessageDispatch.MessageDispatchWebService”已被删除 零应用程序(非基础架构)终结点。这可能是因为 找不到应用程序的配置文件,或者因为 在中可以找到与服务名称匹配的服务元素 配置文件,或者因为在 服务元素..->System.InvalidOperationException:服务 “ISS.MS.WebServices.MessageDispatch.MessageDispatchWebService”已被删除 零应用程序(非基础架构)终结点。这可能是因为 找不到应用程序的配置文件,或者因为 在中可以找到与服务名称匹配的服务元素 配置文件,或者因为在 服务元素 但是,如果我取消选中,页面在浏览器中的加载会很好,但随后我会出现此错误 当我尝试呼叫它时。 服务'ISS.MS.WebServices.MessageDispatch.MessageDispatchWebService' 没有应用程序(非基础架构)终结点。这可能是 因为找不到应用程序的配置文件,或者 因为在中找不到与服务名称匹配的服务元素 配置文件,或者因为在中未定义终结点 服务元素 以下是配置:WCF和SSL的问题,wcf,Wcf,我在使用SSL和WCF使web服务工作时遇到问题 如果我在“需要SSL”页面中签入IIS,则会出现以下错误: WebHost无法处理请求 发件人信息: System.ServiceModel.ServiceHostingEnvironment+HostingManager/36097441 异常:System.ServiceModel.ServiceActivationException:服务 由于编译期间出现异常,无法激活“/”。这个 异常消息是:服务 “ISS.MS.WebServices.
<system.serviceModel>
<services>
<service name="ISS.MS.WebServices.MessageDispatchWcfService">
<endpoint
address=""
binding="basicHttpBinding" bindingConfiguration="basicHttpBinding_MS2"
contract="ISS.MS.WebServices.IMessageDispatchWcfService" />
<endpoint address="mex" binding="mexHttpsBinding" contract="IMetadataExchange" />
</service>
</services>
<behaviors>
<serviceBehaviors>
<behavior>
<serviceDebug includeExceptionDetailInFaults="False" />
<serviceMetadata httpsGetEnabled="true"/>
</behavior>
</serviceBehaviors>
</behaviors>
<bindings>
<basicHttpBinding>
<binding name="basicHttpBinding_MS2" >
<readerQuotas maxStringContentLength="1048576" />
<security mode="Transport">
</security>
</binding>
</basicHttpBinding>
</bindings>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="true">
</serviceHostingEnvironment>
</system.serviceModel>
我可以使用普通的HTTP让它完美地工作,但HTTPs不起作用
我猜这可能是IIS设置或WCF配置问题?我猜出来了,服务和合同的名称不正确……真令人尴尬 有人知道为什么即使这些都不正确,它仍然可以在HTTP上工作吗?(关于“multipleSiteBindingsEnabled”):若要为服务的每个站点启用多个IIS绑定,请将此属性设置为true。请注意,仅HTTP协议支持多站点绑定 参考: 试试这个
<serviceHostingEnvironment aspNetCompatibilityEnabled="true" multipleSiteBindingsEnabled="false">
</serviceHostingEnvironment>
谢谢。这刚刚结束了大约8个小时的调试。