LocalClientSecuritySettings.SessionKeyRenewalInterval 属性
定义
获取或设置一个时间跨度,此时间之后发起方续订用于安全会话的密钥。Gets or sets the time span after which the initiator renews the key for the security session.
public:
property TimeSpan SessionKeyRenewalInterval { TimeSpan get(); void set(TimeSpan value); };
public TimeSpan SessionKeyRenewalInterval { get; set; }
member this.SessionKeyRenewalInterval : TimeSpan with get, set
Public Property SessionKeyRenewalInterval As TimeSpan
属性值
一个表示时间跨度的 TimeSpan,此时间之后发起方续订用于安全会话的密钥。A TimeSpan that represents the time span after which the initiator renews the key for the security session. 默认值为 10 小时。The default is 10 hours.
例外
此属性使用 set 设置为一个小于 0 的值。The property is set to a value less than 0.
示例
此示例演示如何获取此属性。This example shows how to get this property.
TimeSpan sessionKeyRenewalInterval = settings.SessionKeyRenewalInterval;
Dim sessionKeyRenewalInterval As TimeSpan = settings.SessionKeyRenewalInterval
注解
诸如此类的会话设置在以下任何条件下均适用:Session settings such as this one are applicable under any of the following conditions:
WSDualHttpBinding 和 NetTcpBinding 的所有客户端凭据类型。All client credential types for WSDualHttpBinding and NetTcpBinding.
如果已启用 <reliableSession> 元素,则为。If <reliableSession> element is enabled.
如果未启用 <reliableSession> 元素,则在上 WSHttpBinding 为 UserName =
true或 ClientCredentials.Windows =true。If <reliableSession> element is not enabled, on WSHttpBinding with UserName =trueor ClientCredentials.Windows =true.
诸如此类的会话设置在以下任何条件下均不适用:Session settings such as this one are not applicable under any of the following conditions:
对于 BasicHttpBinding。For BasicHttpBinding.
如果未启用 <reliableSession> 元素,则在 WSHttpBinding 带有 ClientCertificate =
true或且没有 ClientCredentials 属性设置为时true。If <reliableSession> element is not enabled, on WSHttpBinding with ClientCertificate =trueor with none of the ClientCredentials properties set totrue.