Achieve Results1) This auxiliary class is mainly used to facilitate the implementation of BASE64-based encryption coding. 2) Base64 is defined as: the Base64 Content transfer code is designed to describe any sequence of 8 bytes as a form that is not easy to be recognized directly. BASE64 encoding is typically found in e-mail messages, open an email to view its original information (you can view it by collecting and exporting the message in a text editor). Encryption is positive, but the purpose of encryption is not to send users a very secure email. This type of encryption is mainly "anti-gentleman against the villain." That is, to reach a glance to completely see the content can be. 3) using BASE64 encoding is not only short, but also has the non-readability, that is, the encoded data will not be directly visible to the human eye.
<summary>
Encrypt a string using the default password table
</summary>
<param name= "Input" > string to encrypt </param>
<returns></returns>
public static string Encrypt (String input)
<summary>
Decrypting a string using the default password table
</summary>
<param name= "Input" > string to Decrypt </param>
<returns></returns>
public static string Decrypt (String input)
<summary>
Gets the cryptographic class with the standard Base64 cipher table
</summary>
<returns></returns>
public static Base64util GetStandardBase64 ()
、、、、、、、、、、、、、
private void Btnbase64_click (object sender, EventArgs e)
{
String original = "This is a test of the Base64 cryptographic string";
String encrypt = Base64util.encrypt (original);
Console.WriteLine (encrypt);//output content: 6l*z5pi_5lia5liq5rwl6k*v55qeqmfzzty05yqg5b*g5b2x56ym5liy
String decrypt = Base64util.decrypt (encrypt);
Debug.Assert (original = = decrypt);//Verify Equality
}
Base64-based encryption-Encoding helper class Base64util