Exemple #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            string key;

            try
            {
                key           = textBoxsqh.Text.Trim();// fAESEncryptor.Decrypt(textBoxsqh.Text.Trim());
                fAESEncryptor = new Elixis.AESEncryptor(key, Elixis.EncryptionOptions.AESBits.BITS256);
                string temp = textBoxRegisterID.Text;
                textBoxRegisterID.Text = fAESEncryptor.Decrypt(temp);
            }
            catch (Exception ex)
            {
                // throw;
            }
        }
Exemple #2
0
        private void buttonRegister_Click(object sender, EventArgs e)
        {
            if (textBoxsqh.Text.Trim() == "")
            {
                return;
            }
            string key;

            try
            {
                fAESEncryptor          = new Elixis.AESEncryptor(GlobalVariables.ElixisPassWordString, Elixis.EncryptionOptions.AESBits.BITS256);
                key                    = fAESEncryptor.Decrypt(textBoxsqh.Text.Trim());
                fAESEncryptor          = new Elixis.AESEncryptor(key, Elixis.EncryptionOptions.AESBits.BITS256);
                textBoxRegisterID.Text = fAESEncryptor.Encrypt("1");
            }
            catch (Exception ex)
            {
                // throw;
            }
        }