What's new
  • ICMag with help from Landrace Warden and The Vault is running a NEW contest in November! You can check it here. Prizes are seeds & forum premium access. Come join in!

LOLcrypt - a way to hide text from LEO by laughing!

PhenoMenal

Hairdresser
Veteran
ok ok so there is absolutely bugger-all security to this so is far from LEO-proof, but i made you look didnt i? :joint:

i just thought of this as i was pissing myself laughing at a joke made by a fellow icmagger. In short, I went LOLLLOLL and realised it was approx 8 fields represented by just two characters. So, if we assume that L = 1, and O = 0, then we can use eight L's and O's to represent one character, or byte.

Example ... to encrypt "YO"
"Y" = 89, which = 01011001 in binary
"O" = 79, which = 01001111 in binary
(if youre wondering where 79 and 89 come from they are the keyboard codes for each character, also known as ASCII codes)

Put the binary together so we get 0101100101001111
Now replace each 1 with L and 0 with O and we get OLOLLOOLOLOOLLLL !

To decrypt you split it into 8 bit chunks, ie. OLOLLOOL and OLOOLLLL
OLOLLOOL = 01011001 in binary, which = 89, which = "Y"
OLOOLLLL = 01001111 in binary, which = 79, which = "O"

See? easy! OLOLOLLLOLLOLOOOOLLOLLLLOLLOOOOLOOLOOOOL OMG !!! *hi 5*

So wherre's my prize for lamest thread of the year then? or did our buddy Trichome Toker get that? :)
 
Last edited:

PhenoMenal

Hairdresser
Veteran
Here's a FREE BONUS! some PHP source code so you can encrypt your own strings into secret LOLs and decrypt those of other people!!


<?
$plainstr = "Wow this is super!"; // String to encrypt

// LOLCrypt PHP Encryption Algorithm v1.0a
for ($i = 0; $i < strlen($plainstr); $i++) {
$encstr = $encstr . sprintf("%08d",decbin(ord(substr($plainstr, $i, 1))));
}
$encstr = ereg_replace("0", "O", $encstr);
$encstr = ereg_replace("1", "L", $encstr);
$encstr = ereg_replace(" ", "", $encstr);
$encstr = ereg_replace(chr(13), "", $encstr);
$encstr = ereg_replace(chr(10), "", $encstr);
echo "Encrypted: " . $encstr . "<br>";

// LOLCrypt PHP Decryption Algorithm v1.0a
$encstr = ereg_replace("O", "0", $encstr);
$encstr = ereg_replace("L", "1", $encstr);
for ($i = 0; $i < strlen($encstr); $i = $i + 8) {
$decstr = $decstr . chr(bindec(substr($encstr, $i, 8)));
}
echo "Decrypted: " . $decstr . "<br>";

?>
 
Last edited:

Kirby

Member
0100001000000110010001101001011101100110100101110011011010010110001001101100011001010010000001100010011110010010000000111000

Your encrypted binary is not divisble by eight.
 

PhenoMenal

Hairdresser
Veteran
It is but there should be no line wrap - it should all be on one line :smile:
(and remove that space from the second line)
 

Kirby

Member
LOOLOLLOLLLOOLLOLOLLOLLOLOOLOLLOLLLOOLLOOLLLOOLOOOOOOLOOOOOOOOLOOOOOOOLLOOLLOOLOOOOOOLOOOOOLOLOOLLOL
 
Top