Exemple #1
0
 private void richTextBox_EncryptionPlanText_TextChanged(object sender, EventArgs e)
 {
     if (richTextBox_EncryptionPlanText.Focused)
     {
         richTextBox_EncryptionEncrypted.Clear();
         if (comboBox_EncryptionMethod.SelectedIndex == 0)
         {
             richTextBox_EncryptionEncrypted.Text = StringCipher.Encrypt(richTextBox_EncryptionPlanText.Text, FConstants.StringCipherKey);
         }
         else if (comboBox_EncryptionMethod.SelectedIndex == 1)
         {
             richTextBox_EncryptionEncrypted.Text = CeasarCipher.Encrypt(richTextBox_EncryptionPlanText.Text);
         }
     }
 }
Exemple #2
0
 public void setPassword(string pass)
 {
     Password = StringCipher.Encrypt(pass, FConstants.StringCipherKey);
 }