コード例 #1
0
ファイル: SSHFP.cs プロジェクト: Vanaheimr/Hermod
 public SSHFP(Stream  Stream)
     : base(Stream, TypeId)
 {
     this._Algorithm    = (SSHFP_Algorithm)       (Stream.ReadByte() & Byte.MaxValue);
     this._Typ          = (SSHFP_FingerprintType) (Stream.ReadByte() & Byte.MaxValue);
     this._Fingerprint  = DNSTools.ExtractName(Stream);
 }
コード例 #2
0
        public SSHFP(Stream Stream)

            : base(Stream, TypeId)

        {
            this._Algorithm   = (SSHFP_Algorithm)(Stream.ReadByte() & Byte.MaxValue);
            this._Typ         = (SSHFP_FingerprintType)(Stream.ReadByte() & Byte.MaxValue);
            this._Fingerprint = DNSTools.ExtractName(Stream);
        }
コード例 #3
0
        public SSHFP(String Name,
                     DNSQueryClasses Class,
                     TimeSpan TimeToLive,
                     SSHFP_Algorithm Algorithm,
                     SSHFP_FingerprintType Typ,
                     String Fingerprint)

            : base(Name, TypeId, Class, TimeToLive)

        {
            this._Algorithm   = Algorithm;
            this._Typ         = Typ;
            this._Fingerprint = Fingerprint;
        }
コード例 #4
0
ファイル: SSHFP.cs プロジェクト: Vanaheimr/Hermod
        public SSHFP(String  Name,
                     Stream  Stream)
            : base(Name, TypeId, Stream)
        {
            this._Algorithm    = (SSHFP_Algorithm)       (Stream.ReadByte() & Byte.MaxValue);
            this._Typ          = (SSHFP_FingerprintType) (Stream.ReadByte() & Byte.MaxValue);

            switch (this._Typ)
            {

                case SSHFP_FingerprintType.SHA1:
                    this._Fingerprint  = BitConverter.ToString(DNSTools.ExtractByteArray(Stream, 20));
                    break;

                case SSHFP_FingerprintType.SHA256:
                    this._Fingerprint  = BitConverter.ToString(DNSTools.ExtractByteArray(Stream, 32));
                    break;

            }
        }
コード例 #5
0
        public SSHFP(String Name,
                     Stream Stream)

            : base(Name, TypeId, Stream)

        {
            this._Algorithm = (SSHFP_Algorithm)(Stream.ReadByte() & Byte.MaxValue);
            this._Typ       = (SSHFP_FingerprintType)(Stream.ReadByte() & Byte.MaxValue);

            switch (this._Typ)
            {
            case SSHFP_FingerprintType.SHA1:
                this._Fingerprint = BitConverter.ToString(DNSTools.ExtractByteArray(Stream, 20));
                break;

            case SSHFP_FingerprintType.SHA256:
                this._Fingerprint = BitConverter.ToString(DNSTools.ExtractByteArray(Stream, 32));
                break;
            }
        }
コード例 #6
0
ファイル: SSHFP.cs プロジェクト: Vanaheimr/Hermod
 public SSHFP(String                 Name,
              DNSQueryClasses        Class,
              TimeSpan               TimeToLive,
              SSHFP_Algorithm        Algorithm,
              SSHFP_FingerprintType  Typ,
              String                 Fingerprint)
     : base(Name, TypeId, Class, TimeToLive)
 {
     this._Algorithm    = Algorithm;
     this._Typ          = Typ;
     this._Fingerprint  = Fingerprint;
 }