连接到安全模式 =“无"的 basicHttpBinding 端点时出现问题
尝试创建一个完全未经身份验证的由 IIS (6) 托管的框架 4.0 WCF basicHttp 服务.部署后,我可以通过浏览器成功检索 WSDL.
Trying to create an framework 4.0 WCF basicHttp service hosted by IIS (6) that is completely unauthenticated. Once deployed, I can successfully retrive the WSDL via a browser.
但是,每当我尝试通过 WCF 测试客户端或通过 Visual Studio 生成的代理连接到它时,我都会收到服务器拒绝了客户端凭据.".
However whenever I try and connect to it via WCF Test Client or via a visual studio generated proxy, I'm getting "The server has rejected the client credentials.".
当我添加 <security mode="None"/>
时仍然会发生这种情况,但我的理解是,无论如何这是默认设置...
This still occurs when I add <security mode="None"/>
, but my understanding is that this is the default anyway ...
在 IIS 虚拟目录属性中,我只勾选了匿名,并且在 web.config 文件中也设置了 <authentication mode="None"/>
.
In the IIS virtual directory properties I only have anonymous ticked, and in the web.config file <authentication mode="None"/>
is set as well.
有什么想法吗?
原来异常的来源是立即尝试连接到下游 tcp 服务.作为一种解决方法,我最终创建了一个普通的 jane webservice 包装器,它使用 <identity impersonate="true" userName=".." password=".." 中指定的域帐户成功连接到下游服务./>
.
Turns out that the source of the exception was from an immediate attempt to connect to a downstream tcp service. As a workaround I ended up creating a plain jane webservice wrapper which successfully connects to the downstream service fine using a domain account specified in the <identity impersonate="true" userName=".." password=".." />
.
注意,我添加了一个相关问题询问为什么一个有效而另一个无效.
Note, I've added a related question asking why one works and the other doesn't.