访问WCF服务时触发MaxClockSkew [英] Triggering MaxClockSkew when accessing WCF service

查看:110
本文介绍了访问WCF服务时触发MaxClockSkew的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个WCF服务,该服务的一个端点的MaxClockSkew配置设置为23:59:59,但是没有安全行为,而另一个端点具有相同的MaxClockSkew配置和安全配置。问题是访问非安全端点时不会引发异常,而访问安全端点时会引发安全异常。我希望两个端点都将引发异常,该怎么办?

I have a WCF service which has one end point with configuration of a MaxClockSkew set to 23:59:59 but with no security behavior, and another end point with the same configuration of MaxClockSkew and security configuration. The problem is when accessing the non secure endpoint no exception is thrown and when accessing the secure endpoint a security exception is thrown. I would like that both of the endpoints will throw exceptions, how can it be done?

谢谢。

Aryeh

推荐答案

安全模式-security mode = Transport-消息中不包含导致MaxClockSkew验证的时间戳忽略该消息并且不引发安全异常。将安全模式更改为security mode = TransportWithMessageCredential,其中包括时间戳,并允许MaxClockSkew验证来测试消息的时间增量。

The security mode - security mode="Transport" - does not include time stamp in the message which cause the MaxClockSkew validation to ignore the message and not throws a security exception. Change the security mode to security mode="TransportWithMessageCredential" which include time stamps and allow the MaxClockSkew validation to test the message for time delta.

这篇关于访问WCF服务时触发MaxClockSkew的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆