Fun Things to Do With Batch Files

355,998

33

135

Posted

Introduction: Fun Things to Do With Batch Files

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)

Step 2: Fun Thing # 2

of course, theres the slightly-more-legal-but-still-annoying-fun field of pranking your friends. these work really well of someone who isn't that computer smart. Of course these are all harmless and will cause no damage. The worst thing that could possibly happen is their computer freezes. they restart. its fine. yippee.

Try this:
@echo off
echo You have been infected.
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
echo The virus will now proceed to delete your entire hard drive.....thank you for being patient...
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
msg * press ok to stop the virus
msg * haha i lied. the virus will now continue :D have a nice day.
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
echo deleting.......
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
echo YOU'VE BEEN FOOLED. THERE IS NO VIRUS.
pause

what it looks like:

Step 3: Ah the Evil One.

This one can be especially mean if you screw with it too much.
There are many variations, because its only one line. all you do is type:

shutdown -f -s -c "your message here".

This will shutdown the computer when run, displaying a timer and a message of your choice.
if you accidentally run this program on yourself, go and type shutdown -a in the command prompt. this aborts the forced shutdown.

see the -f -s -c part? those are arguments. you can use those and the ones in the list below in any combination you like.

-s <- this shuts down the computer
-r <- this restarts the computer
-l <- this logs off the user
-f <- this forces all programs running to shutdown
-t <- this is the time limit until shutdown (the time is in seconds so -t 60 means 60 seconds until the shutdown commences )
try not to mix -s and -r and -l, only use one at a time, as i cannot guarantee what happens when you mix them.

Now you're probably like WTF? i don't know how to use this in a batch file.....no ones dumb enough to run it.....

Solution: Create a shortcut on the desktop, and give it a nice icon / name (something a curious friend will open)
In the box where it says location type your shutdown code (the above stuff)
*curious friend opens it* and his computer shuts down :D
another solution
Tha code:

@echo off
echo you've been infected with a fun little virus that will now wipe out your computer.
echo please wait .........
pathping localhost -q 2 -p 250 > nul
pathping localhost -q 2 -p 250 > nul
echo done!
pathping localhost -q 2 -p 250 > nul
shutdown -f

This closes all their programs, making them think thier drives are wiped :P

Step 4: Just a Reminder

AGAIN: SEND ANY IDEAS FOR A NEW BATCH RELATED (hell, any idea is good, even non batch) INSTRUCTABLE AND I WILL PUBLISH IT (batch preferred though, im really good at that and will get done faster). AGAIN, YOUR NAME WILL BE MENTIONED :D

Dead line is august 27nd. no entries accepted on the 28th.

send ideas here with subject line batch idea:

g_colonna@sympatico.ca

thanks for reading!

~PaRaDoX / Kerpaul (to clarify for those who didn't read my second, yes i'm both of these people.)

Share

Recommendations

  • Minecraft Challenge 2018

    Minecraft Challenge 2018
  • Sew Warm Contest 2018

    Sew Warm Contest 2018
  • Gluten Free Challenge

    Gluten Free Challenge
user

We have a be nice policy.
Please be positive and constructive.

Tips

Questions

141 Comments

DDOS Tool:

@echo off

:menu

title DDOS Tool by WolfBitez

color 0a

echo ==========

echo DDOS Tool

echo ==========

echo.

echo - DDOS

echo - Exit

echo.

set /p op=Run:

if %op%==DDOS goto a

if %op%==ddos goto a

if %op%==Exit goto b

if %op%==exit goto b

:a

cls

title DDOS Execution

echo ==========

echo DDOS Tool

echo ==========

echo.

echo Please name a website to DDOS

echo.

set /p site=Website:

echo.

echo Now select the amount of bytes to DDOS the site with. Ranges from 0-65500.

echo.

set /p packet=Bytes:

echo.

echo Want this to be endless? If so, type -t below. If not, leave it blank.

set /p t=Endless:

echo You are about to DDOS %site% with %packet% bytes of data.

echo Press Ctrl+C to terminate the job.

echo.

ping %site% %t% -l %packet%

ping localhost >nul

cls

goto menu

:b

echo.

echo Thank you for using DDOS tool by WolfBitez.

ping localhost >nul

EXIT

that's a ping script you normie

You know this doesn't work right? It isn't using the right protocol. And technically it would be a DoS tool. "DDoS" means "Distributed denial of service", which means it comes from multiple different computers. "DoS" Means "Denial of service" which means it's coming from one computer.

I msde a batch of an OS Called Windows Basic Editon here is code:
title Windows Basic Editon- Created By Christian James Matthy

X=MsgBox("Welcome To Windows BASIC EDITION!",0+16"Welcome! :DDD")
@echo off
color 1b
cls

@echo off
color 1b
cls

:bootscreen
cls
set /p password= Password:
if %password% == MatthyPlayz desktop
if not %password% == MatthyPlayz goto bootscreentwo

:desktop
cls
color 0a
cls
echo Welcome, Owner Christian Matthy.
echo.
echo Date: %date% Time: %time%
echo
echo 1)Write text file.
echo 2)Documents...
echo 3) Info
echo 4) Calculator
echo 5) Notepad (open in your main Windows OS)
echo 6) Close Windows Basic Edition
echo 7) Open Google (Quick way)
echo 8) Open The Folder Containing This Package (Quick way)
echo 9) randomness
echo 10) matrix
echo 11) Open Info (In a message box)
echo 12) CreateABatch.zip
set /p menuselect=
if %menuselect% == 1 goto write
if %menuselect% == 2 goto docs
if %menuselect% == 3 goto info
if %menuselect% == 4 goto calc
if %menuselect% == 5 goto notepad
if %menuselect% == 6 goto close
if %menuselect% == 7 goto google
if %menuselect% == 8 goto packageinfolder
if %menuselect% == 9 goto random
if %menuselect% == 10 goto randomtwo
if %menuselect% == 11 goto openinfoinmsgbox
if %menuselect% == 12 goto batch
:write
cls
echo Welcome to Write, an application which let's you write text files...
echo What will be the name of your text?
set /p writeone= Name:
cls
echo Ok, your file has been created. Have fun!
pause
cls
set /p textone=
pause
echo You will be going back to the desktop

pause
goto desktop

:docs
cls
echo 1)%writeone%
echo 2)%writetwo%
echo 3)%writethree%
set /p browse=
if %browse% == 1 goto textone
if %browse% == 2 goto texttwo
if %browse% == 3 goto textthree

:textone
cls
echo %writeone%
echo %textone%
pause
goto desktop

:texttwo
cls
echo %writetwo%
echo %texttwo%
pause
goto desktop

:textthree
cls
echo %writethree%
echo %textthree%
pause
goto desktop

:info
echo Windows Basic Edition (Shows Coding)
echo Created by Christian James Matthy
pause
goto desktop

:calc
cls
set /p equ=
set /a equ=%equ%
cls
echo %equ%
pause
goto desktop

:notepad
START /MAX C:\Windows\NOTEPAD.EXE

:close
close

:google
START CHROME www.google.com

:packageinfolder
START F:\
START E:\

:bootscreentwo
goto bootscreen

:random
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%
echo %random%

:randomtwo
echo %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random%
pause
goto desktop

:openinfoinmsgbox
msg * Windows Basic Edition (Shows Coding) Created by Christian James Matthy

:batch
cls
echo Welcome to Project Folder Creator.
echo Will create the following folder:
echo %foldername%
echo If this is okay,
pause
cls

set foldername=Project_ONE


md %foldername%
cd %foldername%


md cache
cd cache
md proxies
cd..


md footage
cd footage
md img seq
cd..


md preview
md projectfiles
md references
md renders
cd renders
md passes
cd..



cls
cd..
start %foldername%
cd %foldername%
echo Batch Complete!
tree
pause

pause
goto desktop

I know it is a bit late but this is almost an instant crash or freeze:

@echo off

Color 0A

title By 321BoB123

Pushd "%~dp0"

:A

Echo %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random% %random%

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

start F_K_D_B.bat

goto A

How do you do the administrator one? It keeps saying access denied.

Press Windows Key + X then click Command Prompt (Admin) and try it again.

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.