Relaxlife.net can encrypt/decrypt ASP code in Chinese/English

Source: Internet
Author: User
Tags decrypt
Encryption | decryption | Chinese relaxlife.net can encrypt/decrypt Chinese/English ASP code for everyone to download, this is confidential, can be used in code encryption

Can encrypt/decrypt Chinese/English ASP code for everyone to download, this is confidential, can be used in code encryption

Function.asp
<%
Rem =================================================================
Rem = function File: function.asp
Rem = Test File: testencrypt.asp,encryptpass.asp
Rem = Description: Encrypt_pro encryption function, Decrypt_pro decryption function
Rem = revision:1.01 Beta
Rem = Author: Shong Hero (cexo255), Qiaoqui
Rem = Date:2005/04/20 03:41:10
Rem = qq:30133499,38377160
Rem = Mysite:http://www.relaxlife.net
Rem = QQ Group: 4341998
Rem = applicable: Encryption of data, or encryption of code, can be encrypted in Chinese/English and so on. Full decryption, will not appear garbled.
Rem = The next version is expected to improve: code algorithms need to rewrite, probably know more people are not very safe.
Rem =================================================================

Public Const sDefaultWHEEL1 = "abcdefghijklmnopqrstvuwxyz_1234567890qwertyuiopasd!@#$%^&* (),. ~ '-=\?/', ' fghjklzxcvbnm<>; '
Public Const sDefaultWHEEL2 = "iwehjktlzvopfg_1234567890qwerbnmqryuasdxcfghjklzxc ~ '-=\?/'" "!@#$%^&* (),. vbnm &LT;&GT;;TYUIOPASD "

Function Encrypt_pro (Sinput, Spassword)
Dim sWHEEL1, sWHEEL2
Dim K, C, I
Dim Sresult
sWHEEL1 = Sdefaultwheel1:swheel2 = sDefaultWHEEL2
Scramblewheels sWHEEL1, SWHEEL2, Spassword
Sresult = ""
For i = 1 to Len (sinput)
c = Mid (Sinput, I, 1)
K = InStr (1, sWHEEL1, c)
If k > 0 Then
Sresult = Sresult & Mid (sWHEEL2, K, 1)
Else
Sresult = Sresult & Addpass (C,spassword)
End If
sWHEEL1 = Leftshift (sWHEEL1): sWHEEL2 = RightShift (sWHEEL2)
Next
Encrypt_pro = Sresult
End Function

Function Decrypt_pro (Sinput, Spassword)
Dim sWHEEL1, sWHEEL2
Dim k, I, C
Dim Sresult
sWHEEL1 = Sdefaultwheel1:swheel2 = sDefaultWHEEL2
Scramblewheels sWHEEL1, SWHEEL2, Spassword
Sresult = ""
For i = 1 to Len (sinput)
c = Mid (Sinput, I, 1)
K = InStr (1, sWHEEL2, C, Vbbinarycompare)
If k > 0 Then
Sresult = Sresult & Mid (sWHEEL1, K, 1)
Else
Sresult = Sresult & Addpass (C,spassword)
&nbs



Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.