Than Posted August 13, 2021 Share Posted August 13, 2021 string keyValue = ""; System.Text.UTF8Encoding UTF8 = new System.Text.UTF8Encoding(); AesManaged tdes = new AesManaged(); tdes.Key = bArr2; tdes.Mode = CipherMode.ECB; tdes.Padding = PaddingMode.PKCS7; ICryptoTransform crypt = tdes.CreateEncryptor(); byte[] plain = Encoding.UTF8.GetBytes(text); byte[] cipher = crypt.TransformFinalBlock(plain, 0, plain.Length); StringBuilder stringBuilder = new StringBuilder(cipher.Length * 2); String encryptedText = Convert.ToBase64String(bArr2); MessageBox.Show(System.Text.Encoding.UTF8.GetString(bArr2)); textBox1.Text = System.Text.Encoding.UTF8.GetString(bArr2); Link to comment Share on other sites More sharing options...
BigDaddyO Posted August 13, 2021 Share Posted August 13, 2021 (edited) I believe you should look at _Crypt_EncryptData in the help file: Specifically Example #2 Edited August 13, 2021 by BigDaddyO Link to comment Share on other sites More sharing options...
Than Posted August 13, 2021 Author Share Posted August 13, 2021 2 hours ago, BigDaddyO said: I believe you should look at _Crypt_EncryptData in the help file: Specifically Example #2 tdes.Key = bArr2; c# can you give me an example of this, thank you Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted August 13, 2021 Moderators Share Posted August 13, 2021 @Than the help file is your friend. Almost every function has at least one, if not multiple, examples: https://www.autoitscript.com/autoit3/docs/libfunctions/_Crypt_EncryptData.htm "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Than Posted August 13, 2021 Author Share Posted August 13, 2021 2 hours ago, JLogan3o13 said: @Than the help file is your friend. Almost every function has at least one, if not multiple, examples: https://www.autoitscript.com/autoit3/docs/libfunctions/_Crypt_EncryptData.htm tdes.Key = bArr2; type byte convert to autoit format key type? i'm not very good at english Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now