The encryption algo I chose was the simple XOR encryption. It's not strong, but then again, if you wanna code a better version then feel free.
strText resembles the text you would like to keep intact
strPW is the password you will use.
Essentially, what happens, is the ASCII is XORed against the password, until all the text is broken into a numeric encrypted array and then posted to whichever site.
strText = "This is the holder text";
strPW = "password";
encText = "";
pwLength = strPW.length;
//XOR crypt the strText with the strPW
//and insert everything into a comma delimitated array of numbers
for (x=0; x<strText.length; x++) {
i = (i%pwLength)+1;
encText += (Number(strText.charCodeAt(x) ^ strPW.charCodeAt(i-1)));
encText += ",";
}
//delete the password from being posted in plaintext
strPW = "";
strText = "";
//post the data
getURL("http://yoursitehere.com/test.php", "_self", "POST");
On the other side, the PHP code catches and decrypts the post
strText = $strText"; ?>
now you can use a function like is_numeric to make sure the integrity of your encrypted data has been kept. Or you could you an MD5 system.
Hope this helps with your score posts!
| » Level Intermediate |
|
Added: 2003-09-21 Rating: 7 Votes: 18 |
| » Author |
| Programmer for www.BleachEatingFreaks.com |
| » Download |
| Download the files used in this tutorial. |
| Download (0 kb) |
| » Forums |
| More help? Search our boards for quick answers! |
-
You must have javascript enabled in order to post comments.


Comments
Hello, Each guy
Posted by migJarZoborma on 11/22/2012 08:20amHi, Everyone I am a greenhand here.I Will appreciate your entire assist. Thanks
Reply