Saturday, June 26, 2010

Top 5 Pranks

We're going to take a step away from the serious topics, and dive into some fun experiences I've had with very simple code. Here are the top 5 most memorable computer pranks I've played on friends, family, coworkers, and other students.  All of these are for Windows computers.

1) Fake Desktop.

Take a screenshot of their desktop, set the image as their background, and hide the the start bar and remove all the icons on their desktop. The result is a desktop that looks exactly the same as before, but nothing can be clicked on.

2) Swap the mouse buttons.

This can be done either through the mouse option in the control pannel or through the registry.

For the registry, you can save the following as a .reg file and run it:
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Control Panel\Mouse]
"SwapMouseButtons"="1"

3) Fun with VB Script

Save the following as c:\prank.vbs:
while( true)
If MsgBox(" is Awesome",vbYesNo) = vbYes Then
WScript.sleep 90000
End If
wend

Then, save the following as prank.reg:
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Run]
"SoundMAXPnPOne"="C:\\prank.vbs"

and run prank.reg (double click on it).
Should be good fun... every 90 seconds it'll prompt them to confirm you are awesome, and will start up when they restart.

4) The browser trainer.


Ocassionally you have the friend that still uses internet explorer. This little script will help train him to use a better browser.

save the following as a .vbs file and run it.
dim obj
set obj = WScript.CreateObject("WScript.Shell")
while(true)
if obj.AppActivate("Internet Explorer") then
wscript.sleep(100)
obj.sendkeys("%{F4}")
MsgBox("Access denied, please use a better browser!")
end if 

wscript.sleep(100)
wend

This can be set to start on boot the same as #3.

5) Remote Control

While I wrote my own application to do this which was a little more undetectable when finding an excuse to learn socket programing(but only allowed me to send button and mouse events and didn't display what they were doing), this can be easily done through free tools like VNC. Simpley install VNC, connect to it from a remote computer and you'll be able to interrupt what they're doing. Maybe slightly move the mouse so they miss click, or type a random key from time to time. Regardless, it's enough to make anyone go insane who doesn't catch on to VNC running in the background.


Lastly, a quick tip for executing some of these pranks. Often, computers in computer labs have pretty strict security settings and won't allow you to easily execute some of these pranks. In many cases, you can open Internet Explorer > File > Open > Browse > Right click > new file > make a new file of the type you need > right click the new file you made> edit > enter the code > save and close > right click the file from the open dialog box > open/run

Many times the windows dialog box still has full access to do everything you need, to save and execute files.

Thursday, June 24, 2010

Evolution, Part 3



As you can tell from the screenshots in “Evolution, part 2”, the program spawns a lot of pop up windows informing me of a multitude of errors. I can’t seem to prevent them, so I made a script to keep an eye out for them and close them as they pop up.


Show VB Script


Not terribly pretty, but effective. Now, I realize there are some serious setbacks to evolution in programs. This is more an experiment of my imagination than it is a serious attempt to make synthetic life. I like to experiment, to find new uses for my code and to push the boundaries of what it was meant to do. What are your thoughts? Is the development of AI through random chaos even a possibility?

Revision three of the code has a lifetime of 300 executions before it quits. From my previous experiments, the code tends to create a functioning copy in a ratio of 1:260 executions.

Once more than 3 instances of the code get going, they start overwriting the file at the same time causing problems. Going forward, I'm going to put together an older computer to let this program run freely, and try to output their executions in a safer manner.

Friday, June 18, 2010

Evolution, Part 2

I ran a few small simulations testing my code from the post below, and quickly added a few changes. It seems a way to stop the spread of programs is essential.


The program mutated several times while maintaining the ability to copy itself. With each byte set to have a 3 in 10,000 chance of changing, roughly 1 in 260 programs could run and reproduce.


I added a 5 second sleep, a file that they update every time they finish running, and a file they read from at the beginning and immediately terminate if it contains the word "stop". These setbacks will provide some basic room for improvement, the first steps of artificial fitness.

Going forward, I think I will require the programs to perform tasks before they can copy themselves. I think I might have them interact with another program that provides challenges, and if they pass, will copy and execute them. They will not have access to directly copy themselves. I look forward to sharing the results and seeing your input!

Thursday, June 17, 2010

Evolution

I always dreamed AI would start from some massive body of code, a huge project worked on by thousands of people. But what if a program needs to develop consciousness much the same way we (most probably) did? That it is simply too complicated to develop without evolving to that point itself. What if a single tiny program, set only to copy itself with a small degree of error, is the start of synthetic life?

I threw together a little concept program last night: show code


The very basics required for evolution seem to be present in our virtual environment: bad mutations will not run, or will crash, and will not be capable of reproducing. The different programs would compete over processor time and storage as they populate our virtual world.

Unfortunately, the virtual world isn’t as harsh as ours. It would be very difficult for random mutations to be beneficial in any way. In fact, it’s likely to start at an optimal solution, and any mutation would simply slow down its ability to reproduce.

In the mean time, I’ll unleash these frequently crashing synthetic progeny to do their bidding as I look to introduce hazards and predators to force a better fitness test that yields beneficial mutations.