Do not use plain text to save the password for the website background database. Otherwise, once a hacker wins your webshell, the consequences are unimaginable.
Most website background password encryption uses the MD5 algorithm.
Today, I am sending you a simple MD5 32-bit encryption program written in C #. Although there is no technical content, there is no backdoor.
Program:
Open source code is as follows:
Using System; Using System. Collections. Generic; Using System. componentmodel; Using System. Data; Using System. drawing; Using System. text; Using System. Windows. forms; Using System. Security. cryptography; Namespace MD5 encryption program { Public Partial Class Form1: FORM { Public Form1 () {initializecomponent ();} Private Void Button#click ( Object Sender, eventargs e ){ String S = Textbox1.text; textbox2.text = Getmd5 (s );} Public Static String Getmd5 ( String Str) {MD5 MD5 = Md5.create (); Byte [] Buffer = Encoding. Default. getbytes (STR ); Byte [] Md5buffer = Md5.computehash (buffer ); String Strnew = "" ; For ( Int I = 0 ; I <md5buffer. length; I ++ ) {Strnew + = Md5buffer [I]. tostring ( " X2 " );} Return Strnew ;} Private Void Label3_click ( Object Sender, eventargs e) {system. Diagnostics. process. Start ( " Http://www.cnblogs.com/xingyunblog/ " );} Private Void Label4_click ( Object Sender, eventargs e) {system. Diagnostics. process. Start ( " Http://bbs.hx95.com/index.php " );}}}
Software:
Link: http://pan.baidu.com/s/1kTzacFt password: 0goe