Exemplo n.º 1
0
 private void buttonGenerate_Click(object sender, EventArgs e)
 {
     PublicKeyAlgorithm algorithm;
     algorithm = this.algorithmBox.Text == "RSA" ? PublicKeyAlgorithm.RSA : PublicKeyAlgorithm.DSA;
     this.labelfingerprint.Hide();
     this.labelpublicKey.Hide();
     this.labelTag.Hide();
     this.textBoxTag.Hide();
     this.publicKeyBox.Hide();
     this.fingerprintBox.Hide();
     this.labelRandomness.Show();
     this.progressBarGenerate.Show();
     this._gotKey = false;
     this._key = null;
     this._OpenSSHstring = "";
     KeyGenThread t = new KeyGenThread(this, algorithm, Int32.Parse(this.bitCountBox.Text));
     this._mmhandler = t.OnMouseMove;
     this.progressBarGenerate.MouseMove += this._mmhandler;
     t.Start();
 }
Exemplo n.º 2
0
        private void buttonGenerate_Click(object sender, EventArgs e)
        {
            PublicKeyAlgorithm algorithm;

            algorithm = this.algorithmBox.Text == "RSA" ? PublicKeyAlgorithm.RSA : PublicKeyAlgorithm.DSA;
            this.labelfingerprint.Hide();
            this.labelpublicKey.Hide();
            this.labelTag.Hide();
            this.textBoxTag.Hide();
            this.publicKeyBox.Hide();
            this.fingerprintBox.Hide();
            this.labelRandomness.Show();
            this.progressBarGenerate.Show();
            this._gotKey        = false;
            this._key           = null;
            this._OpenSSHstring = "";
            KeyGenThread t = new KeyGenThread(this, algorithm, Int32.Parse(this.bitCountBox.Text));

            this._mmhandler = t.OnMouseMove;
            this.progressBarGenerate.MouseMove += this._mmhandler;
            t.Start();
        }