Ejemplo n.º 1
0
 public KeyGenThread(KeyGenForm p, PublicKeyAlgorithm a, Int32 b)
 {
     _parent    = p;
     _algorithm = a;
     _bits      = b;
     _rnd       = new KeyGenRandomGenerator();
 }
Ejemplo n.º 2
0
        void GenerateSSH2Key()
        {
            KeyGenForm dlg = new KeyGenForm();

            dlg.KeyTag = comboBoxKey.Text;
            dlg.ShowDialog();
            if (dlg.Key != null)
            {
                string tag = dlg.KeyTag;
                int    i   = comboBoxKey.FindString(tag);
                if (i >= 0)
                {
                    comboBoxKey.SelectedIndex = i;
                }
                else
                {
                    keysSection.AddKey(tag, dlg.Key.toBase64String());
                    comboBoxKey.Items.Add(tag);
                    comboBoxKey.SelectedIndex = comboBoxKey.FindString(tag);
                }
            }
        }
Ejemplo n.º 3
0
 void GenerateSSH2Key()
 {
     KeyGenForm dlg = new KeyGenForm();
     dlg.KeyTag = comboBoxKey.Text;
     dlg.ShowDialog();
     if(dlg.Key != null)
     {
         string tag = dlg.KeyTag;
         int i = comboBoxKey.FindString(tag);
         if(i>=0)
         {
             comboBoxKey.SelectedIndex = i;
         }
         else
         {
             keysSection.AddKey(tag, dlg.Key.toBase64String());
             comboBoxKey.Items.Add(tag);
             comboBoxKey.SelectedIndex = comboBoxKey.FindString(tag);
         }
     }
 }
Ejemplo n.º 4
0
 public KeyGenThread(KeyGenForm p, PublicKeyAlgorithm a, Int32 b)
 {
     _parent = p;
     _algorithm = a;
     _bits = b;
     _rnd = new KeyGenRandomGenerator();
 }