Пример #1
0
 /// <summary>
 ///   Creates a new instance of the IpSecKeyRecord class
 /// </summary>
 /// <param name="name"> Name of the record </param>
 /// <param name="timeToLive"> Seconds the record should be cached at most </param>
 /// <param name="precedence"> Precedence of the record </param>
 /// <param name="gatewayType"> Type of gateway </param>
 /// <param name="algorithm"> Algorithm of the key </param>
 /// <param name="gateway"> Address of the gateway </param>
 /// <param name="publicKey"> Binary data of the public key </param>
 public IpSecKeyRecord(string name, int timeToLive, byte precedence, IpSecGatewayType gatewayType, IpSecAlgorithm algorithm, string gateway, byte[] publicKey)
     : base(name, RecordType.IpSecKey, RecordClass.INet, timeToLive)
 {
     Precedence  = precedence;
     GatewayType = gatewayType;
     Algorithm   = algorithm;
     Gateway     = gateway ?? String.Empty;
     PublicKey   = publicKey ?? new byte[] { };
 }
Пример #2
0
 /// <summary>
 /// Creates a new instance of the IpSecKeyRecord class
 /// </summary>
 /// <param name="name"> Name of the record </param>
 /// <param name="timeToLive"> Seconds the record should be cached at most </param>
 /// <param name="precedence"> Precedence of the record </param>
 /// <param name="gatewayType"> Type of gateway </param>
 /// <param name="algorithm"> Algorithm of the key </param>
 /// <param name="gateway"> Address of the gateway </param>
 /// <param name="publicKey"> Binary data of the public key </param>
 public IpSecKeyRecord(string name, int timeToLive, byte precedence, IpSecGatewayType gatewayType, IpSecAlgorithm algorithm, string gateway, byte[] publicKey)
     : base(name, RecordType.IpSecKey, RecordClass.INet, timeToLive)
 {
     this.Precedence = precedence;
     this.GatewayType = gatewayType;
     this.Algorithm = algorithm;
     this.Gateway = gateway ?? String.Empty;
     this.PublicKey = publicKey ?? new byte[] { };
 }