首页 新闻 赞助 找找看

WCF 配置

0
悬赏园豆:10 [已解决问题] 解决于 2010-06-21 09:42

WCF配置中的wsHttpBinding中的节点 <message clientCredentialType="UserName" establishSecurityContext="false" negotiateServiceCredential="false" />

后面两个属性的的默认设置是True,它们的详细作用是什么?如果设为false会有什么影响?

我将这两个属性设为false后明显感觉速度有很大提升。

luotong的主页 luotong | 初学一级 | 园豆:4
提问于:2010-06-10 11:28
< >
分享
最佳答案
0

negotiateServiceCredential此属性指示是否在客户端和服务之间自动协商服务证书。如果此属性为 true,则会进行此类协商。如果此属性为 false,则与服务通信之前必须在客户端指定服务证书。

服务必须始终指定一个证书。

establishSecurityContext此属性控制安全上下文令牌是否通过客户端与服务之间的 WS-SecureConversation 交换建立。将它设置为 true 要求远程方支持 WS-SecureConversation

收获园豆:5
winzheng | 大侠五级 |园豆:8797 | 2010-06-10 13:10
其他回答(1)
0

这个你看下msdn的解释。

1.negotiateServiceCredential.

属性值

类型:System..::.Boolean
如果通过协商过程获取服务凭据,则为 true;否则为 false。默认值为 truehttp://msdn.microsoft.com/zh-cn/library/system.servicemodel.messagesecurityoverhttp.negotiateservicecredential(VS.90).aspx

2。establishSecurityContexttrue if a secure conversation is established using SecurityContextToken security tokens; otherwise, false. The default is false.

http://msdn.microsoft.com/zh-cn/library/microsoft.web.services3.design.securitypolicyassertion.establishsecuritycontext(en-us).aspx

收获园豆:5
Frank Xu Lei | 园豆:1860 (小虾三级) | 2010-06-12 12:58
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册