**** This is a small article, a much larger one will be done later *****
For all those who have been slapped down by restrictions at school, look no further.
Before I start, this is a warning. This article involves editting the Registry Editor.
([WARNING:]) Editting the Registry Editor without proper knowlegde is extremely
dangerous. Doing so may result in your computer booting improperly and not working. If possible, make backups,
and be careful at all times.
I recently got tired of school restrictions, so I made a little program in C.
Now its not the best, as i dont expect it to be; considering its my first C program.
Im going to talk about somethings it does and show you some code you can compile yourself.
If you are unfamiliar with the registry, please visit
http://en.wikipedia.org/wiki/Windows_registry In computing, the Windows registry is a database
which stores settings and options for the operating system for Microsoft Windows
32-bit versions. It contains information and settings for all the hardware,
software, users, and preferences of the PC. Whenever a user makes changes to
"Control Panel" settings, or file associations, system policies, or installed
software, the changes are reflected and stored in the registry.[/quote]
First, im going to show and explain how to gain access to the control panel of your computer. Im not
sure about your school, but gaining access to Administrator only gave me control of the computer I was at, so
dont get too hot of a head.
Here is a section of code that worked.
#include <windows.h>
#include <stdio.h>
#include <stdlib.h>
int main(int argc, char *argv[])
{
# Or take the lazy way out and use REGEDIT.EXE.
#If blocked, start from COMMAND.COM
printf("\n Enable CP\n");
printf("\n Dont do too much damage. Have fun.\n\t");
system("PAUSE");
system("reg add \\\"HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System\\\" /v NoDispCPL /t REG_DWORD /d 0 /f");
system("reg add \\\"HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\Explorer\\\" /v NoControlPanel /t REG_DWORD /d 0 /f");
system("taskkill /im explorer.exe /f");
system("start explorer.exe");
return 0;
}
Lets take notice to the two most important lines, lines 9 & 10.
system("reg add \\\"HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System\\\" /v NoDispCPL /t REG_DWORD /d 0 /f");
As you will notice, this is executed through the CMD. If your school has bad security practices, then doing so WITHOUT the help
of compiling it into an exe might be the better way out. However, those of us with schools with brains, keep reading.
Although most school will block the CMD, they will not block commands sent to them. This goes for batch programming too. Hey, take the easy
way out with Batch files. Who cares.
Back to focus. "reg add" is the basic query, and you guessed it, it adds the following to the Registry Editor. If the line already exists in the
RegEdit, it will override it.
\\\"HKCU\\Software\\Microsoft\\Windows\\CurrentVersion\\Policies\\System\\\"
Notice the \\ before the actual english. Its escaping characters. I want a \ in the code, so i need to put another \ to allow it. So
to allow \ in it, i actually put \\. The \" is escaping the ".
HKCU is just short for HKEY_CURRENT_USER. The rest is simply the destination.
The syntax is like this:
REG QUERY KeyName [/v ValueName | /ve] [/s]
As shown, the "/v NoDispCPL" is the valuename we want to edit. The "/t REG_DWORD" is the reg type data. This ranges from strings to binary.
The "/d 0" is the value we are setting. 0 meaning the restriction is NOT in place. Similarly, 1 means restricted. The "/f" at the end simply
means it is not going to ask "Are you sure?". We dont need confirmation, we know what we are doing.
The part after of
system("taskkill /im explorer.exe /f");
system("start explorer.exe");
I use this for the changes to take effect. No need to log out when you can do this now can yah?
If you were to compile the code above (language C) in something such as Dev-C++, you would have a nifty little feature.
Cant let the man keep us down.
Also, don't be lame. This is for example. Code yourself

Good article. It's just too bad that regedit.exe is disabled on all the computers at my school.
great article! :) i didnt much know about the reg command.. it was a good primer.. also reminded me the good old taskkill /im the cousin of linux kill.