Exemple #1
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     while (!reader.IsEndOfLine())
     {
         Strings.Add(reader.ReadString());
     }
 }
Exemple #2
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     Flags     = (DNSKEYFlags)reader.ReadUInt16();
     Protocol  = reader.ReadByte();
     Algorithm = (SecurityAlgorithm)reader.ReadByte();
     PublicKey = reader.ReadBase64String();
 }
Exemple #3
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     NextOwnerName = reader.ReadDomainName();
     while (!reader.IsEndOfLine())
     {
         Types.Add(reader.ReadDnsType());
     }
 }
Exemple #4
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     PrimaryName  = reader.ReadDomainName();
     Mailbox      = reader.ReadDomainName();
     SerialNumber = reader.ReadUInt32();
     Refresh      = reader.ReadTimeSpan32();
     Retry        = reader.ReadTimeSpan32();
     Expire       = reader.ReadTimeSpan32();
     Minimum      = reader.ReadTimeSpan32();
 }
Exemple #5
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     Algorithm         = reader.ReadDomainName();
     TimeSigned        = reader.ReadDateTime();
     Fudge             = reader.ReadTimeSpan16();
     MAC               = Convert.FromBase64String(reader.ReadString());
     OriginalMessageId = reader.ReadUInt16();
     Error             = (MessageStatus)reader.ReadUInt16();
     OtherData         = Convert.FromBase64String(reader.ReadString());
 }
Exemple #6
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     Algorithm  = reader.ReadDomainName();
     Inception  = reader.ReadDateTime();
     Expiration = reader.ReadDateTime();
     Mode       = (KeyExchangeMode)reader.ReadUInt16();
     Error      = (MessageStatus)reader.ReadUInt16();
     Key        = Convert.FromBase64String(reader.ReadString());
     OtherData  = Convert.FromBase64String(reader.ReadString());
 }
Exemple #7
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     TypeCovered         = reader.ReadDnsType();
     Algorithm           = (SecurityAlgorithm)reader.ReadByte();
     Labels              = reader.ReadByte();
     OriginalTTL         = reader.ReadTimeSpan32();
     SignatureExpiration = reader.ReadDateTime();
     SignatureInception  = reader.ReadDateTime();
     KeyTag              = reader.ReadUInt16();
     SignerName          = reader.ReadDomainName();
     Signature           = reader.ReadBase64String();
 }
Exemple #8
0
        /// <inheritdoc />
        public override void ReadData(PresentationReader reader)
        {
            HashAlgorithm = (DigestType)reader.ReadByte();
            Flags         = reader.ReadByte();
            Iterations    = reader.ReadUInt16();

            var salt = reader.ReadString();

            if (salt != "-")
            {
                Salt = Base16.Decode(salt).ToArray();
            }
        }
Exemple #9
0
        /// <inheritdoc />
        public override void ReadData(PresentationReader reader)
        {
            KeyTag        = reader.ReadUInt16();
            Algorithm     = (SecurityAlgorithm)reader.ReadByte();
            HashAlgorithm = (DigestType)reader.ReadByte();

            // Whitespace is allowed within the hexadecimal text.
            var sb = new StringBuilder();

            while (!reader.IsEndOfLine())
            {
                sb.Append(reader.ReadString());
            }
            Digest = Base16.Decode(sb.ToString()).ToArray();
        }
Exemple #10
0
        /// <inheritdoc />
        public override void ReadData(PresentationReader reader)
        {
            HashAlgorithm = (DigestType)reader.ReadByte();
            Flags         = (NSEC3Flags)reader.ReadByte();
            Iterations    = reader.ReadUInt16();

            var salt = reader.ReadString();

            if (salt != "-")
            {
                Salt = Base16.Decode(salt).ToArray();
            }

            NextHashedOwnerName = Base32.ExtendedHex.Decode(reader.ReadString()).ToArray();

            while (!reader.IsEndOfLine())
            {
                Types.Add(reader.ReadDnsType());
            }
        }
 /// <summary>
 ///   Read the textual representation of the data that is specific to
 ///   the resource record <see cref="Type"/>.
 /// </summary>
 /// <param name="reader">
 ///   The source of the resource record's data.
 /// </param>
 /// <remarks>
 ///   Derived classes must implement this method.
 /// </remarks>
 public virtual void ReadData(PresentationReader reader)
 {
 }
 /// <inheritdoc />
 public ResourceRecord Read(PresentationReader reader)
 {
     return(reader.ReadResourceRecord());
 }
Exemple #13
0
 /// <inheritdoc />
 public override void ReadData(PresentationReader reader)
 {
     Address = reader.ReadIPAddress();
 }