Hiding easter eggs in web scripts

Started by
13 comments, last by CWizard 19 years, 1 month ago
You need obfuscation. I've hidden eggs in all kinds of things, including heavily peer-reviewed projects, without problems. If you play it right, it takes so long for the egg to even be discovered that by the time someone finds it, the original client doesn't care. Usually you can even get a laugh or three.

Start with very wrong comments and symbols, as suggested - but make the thing as complicated as possible to discourage reverse-engineering. One of my favorite eggs is just a simple text-injection that prints "Apoch was here" into a text stream at a strategic time. It was controlled by four separate functions and the actual text was "encoded" in the form of several constants and constant arrays that were combined mathematically to produce the final string. Even better, the formula that decoded the constants made use of other perfectly legitimate constants, so it blended in with the surrounding code and looked innocent.

Wielder of the Sacred Wands
[Work - ArenaNet] [Epoch Language] [Scribblings]

Advertisement
I'm definitely going for this obfuscation thing. I have the perfect place for it to... I just need to figure out a clever way of composing it from innocent-looking constants.

Quote:Original post by WanMaster
Why not just generate a picture using php and add it to the response stream?


Yes, why not? But how?
Nein heer du smign. ah open up the nine im heer du shmine
Quote:Original post by Boris Karloff
I'm definitely going for this obfuscation thing. I have the perfect place for it to... I just need to figure out a clever way of composing it from innocent-looking constants.

Quote:Original post by WanMaster
Why not just generate a picture using php and add it to the response stream?


Yes, why not? But how?


Well, you could always use the PHP image generation functions (look in the PHP manual extended CHM for details) - a few "circle" commands are all that are needed.

[Website] [+++ Divide By Cucumber Error. Please Reinstall Universe And Reboot +++]

Place in something like

document.writein("<scr" + "ipt language="&#106avascript" src='Adds.js' \>")

Then in adds.js, you do the adds and the easter eggs (or one easter egg).

In adds, you go and you store an encrypted script, which you then writein (and decrypt) when the time comes (But you need to make sure that noone stumbles upon it.

From,
Nice coder
Click here to patch the mozilla IDN exploit, or click Here then type in Network.enableidn and set its value to false. Restart the browser for the patches to work.
Quote:Original post by Boris Karloff
Quote:Original post by WanMaster
Why not just generate a picture using php and add it to the response stream?


Yes, why not? But how?

http://www.php.net/manual/en/ref.image.php

It is really simple.

EDIT: Note: you cannot just send out the image when generating the document. In the document, you must create an object which URI invokes some PHP code that may generate the image under certain conditions.

This topic is closed to new replies.

Advertisement