Esempio n. 1
0
        public override byte[] CreateKeyAndCertificatesData()
        {
            using (var worker = new SshDataWorker()) {
                var args = this.algorithm.ExportParameters(false);

                worker.Write(this.Name, Encoding.ASCII);
                worker.WriteMpint(args.Exponent);
                worker.WriteMpint(args.Modulus);

                return(worker.ToByteArray());
            }
        }
Esempio n. 2
0
        public override byte[] CreateKeyAndCertificatesData()
        {
            using (var worker = new SshDataWorker())
            {
                var args = _algorithm.ExportParameters(false);

                worker.Write(this.Name, Encoding.ASCII);
                worker.WriteMpint(args.Exponent);
                worker.WriteMpint(args.Modulus);

                return worker.ToByteArray();
            }
        }
Esempio n. 3
0
 protected override void OnGetPacket(SshDataWorker writer)
 {
     writer.WriteBinary(this.HostKey);
     writer.WriteMpint(this.F);
     writer.WriteBinary(this.Signature);
 }
 protected override void OnGetPacket(SshDataWorker writer)
 {
     writer.WriteBinary(HostKey);
     writer.WriteMpint(F);
     writer.WriteBinary(Signature);
 }