[英]WCF Says my settings require 'Anonymous' authentication - but I don't want them
因此, 这个问题与我的问题完全相同。
此服务的安全设置需要“匿名”身份验证,但是承载此服务的IIS应用程序未启用该身份验证。
但是,我已经从Web配置中删除了mex
端点,但仍然出现相同的错误。 我的网络配置如下所示:
<system.serviceModel>
<services>
<service name="xxx.MessageHub.MessageHubService"
behaviorConfiguration="default">
<endpoint binding="wsHttpBinding"
contract="xxx.MessageHub.IMessageHubService" />
</service>
</services>
<behaviors>
<endpointBehaviors>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="default">
<!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
<serviceMetadata httpGetEnabled="true"/>
<!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information -->
<serviceDebug includeExceptionDetailInFaults="true"/>
<serviceAuthorization principalPermissionMode="UseWindowsGroups" />
</behavior>
</serviceBehaviors>
</behaviors>
<bindings>
<basicHttpBinding>
<binding name="credsOnly">
<security mode="TransportCredentialOnly">
<transport clientCredentialType="Windows"></transport>
</security>
</binding>
</basicHttpBinding>
<wsHttpBinding>
<binding name="transport">
<security mode="Transport">
<transport clientCredentialType="Windows"></transport>
</security>
</binding>
</wsHttpBinding>
</bindings>
</system.serviceModel>
我正在运行具有IIS6兼容性并添加到IIS7的应用程序(因为我们的产品服务器运行IIS6-部署到测试服务器时会遇到相同的异常)。
我需要修复哪些设置才能使此功能正常工作?
我可以按照在此msdn帖子中找到的步骤(略有修改)来解决此问题:
通过从下拉列表中选择此选项,将BindingConfiguration属性设置为WsHttpEndpointBinding 。 这会将绑定配置设置与绑定相关联。
在配置编辑器的“文件”菜单上,单击“保存”。
并且(据我所知)这提供了使用集成身份验证(而不是Windows集成)的身份验证。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.