public AcceptorSessionSymmetricTransportSecurityProtocol(SessionSymmetricTransportSecurityProtocolFactory factory) : base(factory, null, null) { if (factory.ActAsInitiator) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidOperationException(System.ServiceModel.SR.GetString("ProtocolMustBeRecipient", new object[] { base.GetType().ToString() }))); } this.requireDerivedKeys = factory.SecurityTokenParameters.RequireDerivedKeys; }
public AcceptorSessionSymmetricTransportSecurityProtocol(SessionSymmetricTransportSecurityProtocolFactory factory) : base(factory, null, null) { if (factory.ActAsInitiator == true) { Fx.Assert("This protocol can only be used at the recipient."); throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new InvalidOperationException(SR.GetString(SR.ProtocolMustBeRecipient, this.GetType().ToString()))); } this.requireDerivedKeys = factory.SecurityTokenParameters.RequireDerivedKeys; }
public InitiatorSessionSymmetricTransportSecurityProtocol(SessionSymmetricTransportSecurityProtocolFactory factory, EndpointAddress target, Uri via) : base(factory, target, via) { this.thisLock = new object(); if (!factory.ActAsInitiator) { throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new NotSupportedException(System.ServiceModel.SR.GetString("ProtocolMustBeInitiator", new object[] { "InitiatorSessionSymmetricTransportSecurityProtocol" }))); } this.requireDerivedKeys = factory.SecurityTokenParameters.RequireDerivedKeys; }
public InitiatorSessionSymmetricTransportSecurityProtocol(SessionSymmetricTransportSecurityProtocolFactory factory, EndpointAddress target, Uri via) : base(factory, target, via) { if (factory.ActAsInitiator != true) { Fx.Assert("This protocol can only be used at the initiator."); throw DiagnosticUtility.ExceptionUtility.ThrowHelperError(new NotSupportedException(SR.GetString(SR.ProtocolMustBeInitiator, "InitiatorSessionSymmetricTransportSecurityProtocol"))); } this.requireDerivedKeys = factory.SecurityTokenParameters.RequireDerivedKeys; }