Using system; using system.text; using system.security.cryptography;
Namespace Common {///
///
///
///
Public crypto () {// // Todo: Add constructor logic here //}
///
Byte [] INPUTBYTEARRAY = System.Text.Encoding.utf8.getbytes (Strentext);
// You can also create additional decryption class instances, but pay attention to different (length) encryption classes require different key Key and initialization vector IV rijndaelmanaged rmcrypto = new rijndaelManaged ();
MemoryStream ms = new MemoryStream (); CryptoStream cs = new CryptoStream (ms, RMCrypto.CreateEncryptor (EnKey, EnIV), CryptoStreamMode.Write); cs.Write (inputByteArray, 0, inputByteArray.Length); cs.FlushFinalBlock ();
Return Convert.TOBASE64STRING (ms.toarray ());}
///
// You can also create additional decryption class instances, but pay attention to different encryption classes require different (length) Key Key and initialization vector IV RijndaelManaged RMCrypto = new rijndaelManaged ();
MemoryStream ms = new MemoryStream (); CryptoStream cs = new CryptoStream (ms, RMCrypto.CreateDecryptor (DeKey, DeIV), CryptoStreamMode.Write); cs.Write (inputByteArray, 0, inputByteArray.Length); cs.FlushFinalBlock ();
Return System.Text.Encoding.utf8.getstring (ms.toarray ());}}} Some of the following data encrypted below, I can't summarize these data into valuable expression, I hope you don't worry. Enlightenment:
Admiral English letters, digital length range encrypted before Chinese characters long range encryption length size 0-150-52416-316-104432-4711-15648-6316-208864-7921-1510880-9516-3012896-1113-35152