Blade Edge

Computer software | Video production | My life in general

Blade Edge about header

Confessions of a Teenage “Hacker”: Part 2

February 27th, 2009 · 6 Comments · Personal

So, I’ve already confessed to the evil deed of stealing my father’s internet password, now as promised I will declassify the operation codenamed… uhm… crap I never thought to give this project a code name. How lame is that? LAME!! Well, anyways it was an operation that took place in my high school AP Computer Science class derived from a little snippet of information I gleaned out of Andre LaMothe’s Tricks of the Windows Game Programming Gurus book of waaay back in the day (way back). I don’t have the book with me anymore – at least I can’t find it – I’d like to think I sold it but how the hell I managed that I have no idea so it must be lost somewhere. Anyways in one of the chapters discussing Windows messaging Andre made a little note about the WM_CLOSE message. Specifically, he revealed that if you intercepted the message but failed to handle it, the application would simply not close. Like, at all. He then proceeded to issue a casual challenge: if anyone could think up a use for this little loophole, to send him an email about it.

Well, I did. On both counts. I don’t have the email I sent him anymore, so we’ll just focus on the use of the message loophole, since that’s more interesting anyways.

I’ll first set the stage by explaining that my AP Computer Science class was taught by my math teacher, Mrs. Simes, who had to have seriously been like 60 years old at the time. In the years since, I have grown to pity her and even appreciate the effort she put in trying to teach out of a book while attempting to stay at least a chapter ahead of her students. Of course, at the time I held pretty much nothing but contempt for this wizened old lady attempting to teach me things I had learned two years ago on my own. The fact that she was also my math teacher, and I hated math (still do, mostly) didn’t help matters in the slightest. So here I am, stuck in this AP class bored out of my skull listening to Simes bumbling along and cooperating as best I could only because my lack of interest in school in general meant that this AP course would probably be the main thing that lets me graduate high school.

Okay so, back to the WM_CLOSE message. Upon learning of this feature, I immediately created a Win32 application that implemented it. Sure enough, no matter what I tried (Esc, Alt+F4, context menu, Close button) the window failed to respond and just sat there. Ctrl+Alt+Del was the only solution. I’d like to think that at this point I laughed maniacally and rubbed my hands together with manic glee – so I’ll just say that’s what I did. The next question was where to unleash this wonderful weapon of doom and who to target specifically, since it would need to be placed on a certain computer. Well, the where was pretty obvious: the AP CS class was just ripe for pranks. This narrowed down the who significantly since the classes were small and many of the students were actually technically savvy (whodathunk?). So of the few students who did not have any real technical know-how, I of course chose the most volatile. I won’t mention her name here but her initials are Lisa T. (I wimped out and kept her full last name private. I must be getting nice in my old age)

And let’s just pause for a second here so I can say that I held no ill will in particular towards Lisa – she was just the ideal candidate for my prank. Sorry Lisa.

Sort of.

Right, so with my target chosen I had to properly spruce up my weapon, which I did by including message handlers for pressing the Esc key, exiting via the context menu, pressing Alt+F4, clicking the Close button and even pressing Q and X. All these handlers pointed towards a dialog box which read from a resource of messages that became incrementally more taunting as the user (target) tried more and more means of attempting to close this window. I then made the window start up by filling the entire width and height of the screen. Then I removed the Minimize and Restore buttons. Finally, I gave everyone a fair warning by titling the window “The Window That REALLY Won’t DIE”. Just as I thought I was done my plan took an even more devious turn, and I added a dialog box to pop up when the program is first run – but more on that later.

Weapon completed, I then had to assemble my delivery system. Fortunately, we all had assigned computers, so I knew which computer Lisa would be logging into. Unfortunately, she had class in a different period than me so I had to recruit an evil sidekick, my friend Andrew Owendoff. I gave Andrew a disk with the program executable on it and he walked into class early, turned on Lisa’s computer, inserted and copied over the file to a specific and highly strategic location, ran the app, cleared the opening dialog box, and then turned off her computer monitor.

Showtime. (Note that the following is based on second-hand reports from Andrew since I couldn’t (unfortunately – dammit!) be present, with minor dramatization for effect)

Poor unassuming Lisa comes to class and turns on her computer monitor. Lisa: Oh my! What is this window on my screen? Oh well, no matter, just shrug and hit Close… wait… wait what? Why is this message telling me I never learn? Oh well just close this and… why is this window still open?? I must have made a mistake. Click on Close and… another message?!? What’s happening? Help! Mrs. Simes help!!

Over toddles Mrs. Simes, who squints through her bifocals at the screen and suggests “Well why don’t you hit the Close button”. Oh yes. Fabulous success!! The pair continue to be taunted by the application as Mrs. Simes grows increasingly confounded and poor Lisa reportedly just resorts to crying. Finally Simes gets completely fed up and simply restarts the computer. However, due to my foresight and the aforementioned strategic location in which the executable was placed, upon the restart of Windows a message box pops up:

Yes. I had Andrew place the program in the Startup folder. I know. Genius. Erm, evil genius, that is.

The next step was of course to call down the school’s network and computer supervisor, who seriously didn’t know much more than poor old Mrs. Simes. Some time later and after continuous frustration from trying to eradicate this program from the computer or even close it, they turned at last to their final remaining option: Consultation of the student who was rolling around on the floor laughing hysterically, who just so happened to share the same name as me. Coincidence? They thought not. After threatening Andrew with suspension he finally gave up that you have to task-kill the application and that he theorized the executable was in the Startup folder. However he maintained he didn’t know how it got there or who had put it there.

I remember when I stepped into class a few periods later Mrs. Simes made a beeline for my desk, but my “who, me?” face had been well-practiced over the years of my youth, and so I was never officially fingered as the culprit and the crime passed on into the annals of legend.

Best of all? I still have that application thanks to my pack rat nature. If you’d like a gander, feel free to download it (with source) and use it for whatever diabolical plans you come up with – don’t forget to write me letters from federal prison either. Swear I’ll write back. If I’m inside at the time we can do lunch.

Tags:

6 Comments so far ↓

  • Tracy

    I found your blog by random and read this article… I once had a plan quite similar to this one. It in fact took place in my High School computer class. My program was slightly more devious :D. The night before class I was programming .bat files trying to make an auto-installer for all my programs for use after a format ( a story for another time). While attempting to learn and looking around windows I found a program called logoff.exe… curious. I built a batch that would launch logoff.exe whenever someone logged on Hahaha… and stored it in the startup program. Genius, I thought to myself. Turns out I was unsure how to stop this notorious villian. In the end I realized if I pressed pause at just the right moment I could halt the script. After several hoaxes on the school computers I destroyed the script. No man shall have its power! I could only imagine how difficult it would be to halt on modern computers…

  • Gaiiden

    haha, wow that is quite diabolical. Very nice thank you for sharing 🙂

    Some more notorious pranks were of course pulled by classmates as well. One kid actually got suspended *and* kicked out of the AP class for writing a program that would open a text file, write random data to it until it reached the max size, then open another text file and repeat… it would run in the background so it would slowly eat up the entire computer's disk space. It go distributed onto a number of PCs 😛

  • Tracy

    I found your blog by random and read this article… I once had a plan quite similar to this one. It in fact took place in my High School computer class. My program was slightly more devious :D. The night before class I was programming .bat files trying to make an auto-installer for all my programs for use after a format ( a story for another time). While attempting to learn and looking around windows I found a program called logoff.exe… curious. I built a batch that would launch logoff.exe whenever someone logged on Hahaha… and stored it in the startup program. Genius, I thought to myself. Turns out I was unsure how to stop this notorious villian. In the end I realized if I pressed pause at just the right moment I could halt the script. After several hoaxes on the school computers I destroyed the script. No man shall have its power! I could only imagine how difficult it would be to halt on modern computers…

  • Gaiiden

    haha, wow that is quite diabolical. Very nice thank you for sharing 🙂

    Some more notorious pranks were of course pulled by classmates as well. One kid actually got suspended *and* kicked out of the AP class for writing a program that would open a text file, write random data to it until it reached the max size, then open another text file and repeat… it would run in the background so it would slowly eat up the entire computer's disk space. It go distributed onto a number of PCs 😛

  • Blade Edge Software Source Release

    […] of contacting my old high school and seeing what’s become if the Computer Science AP program I terrorized back when I was in school. I might pay them a visit as […]

  • Erik

    this blog had me laughing so hard
    I remember back in ’08 the IT dept bought about 30 2nd hand PCs and didn’t wipe the hard drives, so every user ended up with a different Windows OS, all the way down from XP to Win95 and Win3.11 (would you believe it?)

Leave a Comment