3 Simple Ways to
Share What You Make

With Instructables you can share what you make with the world — and tap into an ever-growing community of creative experts.

PhotosPhotos

Share one or more photos of a project, recipe, or whatever you've made, quickly and easily.

Step by StepStep-By-Step

Share your step-by-step photos with text instructions of what you made so others can do it too!

VideoVideo

Share your how-to video. You'll need your embed code from a video site such as YouTube.

5 Cool Batch Files

5 Cool Batch Files
In This instructable you will get 5 codes for 5 useful batch things

- Password Generator
- Password Protected Command Prompt
- Website Crasher
- Website Pinger
- PC Cleanup Utilities
 
Remove these adsRemove these ads by Signing Up
 

Step 1Password Generator

Password Generator

This Batch generates number only passwords. You can choose from 1, 5. or 10 passowrds to show...all random

Code:

@echo off
:Start2
cls
goto Start
:Start
title Password Generator
echo I will make you a new password.
echo Please write the password down somewhere in case you forget it.
echo ----------------------------------------­-----------------------
echo 1) 1 Random Password
echo 2) 5 Random Passwords
echo 3) 10 Random Passwords
echo Input your choice
set input=
set /p input= Choice:
if %input%==1 goto A if NOT goto Start2
if %input%==2 goto B if NOT goto Start2
if %input%==3 goto C if NOT goto Start2
:A
cls
echo Your password is %random%
echo Now choose what you want to do.
echo 1) Go back to the beginning
echo 2) Exit
set input=
set /p input= Choice:
if %input%==1 goto Start2 if NOT goto Start 2
if %input%==2 goto Exit if NOT goto Start 2
:Exit
exit
:B
cls
echo Your 5 passwords are %random%, %random%, %random%, %random%, %random%.
echo Now choose what you want to do.
echo 1) Go back to the beginning
echo 2) Exit
set input=
set /p input= Choice:
if %input%==1 goto Start2 if NOT goto Start 2
if %input%==2 goto Exit if NOT goto Start 2
:C
cls
echo Your 10 Passwords are %random%, %random%, %random%, %random%, %random%, %random%, %random%, %random%, %random%, %random%
echo Now choose what you want to do.
echo 1) Go back to the beginning
echo 2) Exit
set input=
set /p input= Choice:
if %input%==1 goto Start2 if NOT goto Start 2
if %input%==2 goto Exit if NOT goto Start 2
« Previous StepDownload PDFView All StepsNext Step »
17 comments
Apr 22, 2012. 4:36 PMben35ben34 says:
so cool
Apr 22, 2012. 4:34 PMben35ben34 says:
echo off
color 0a
Echo °°°° °°°°° °°°°°
Echo °°°°°°° °² °°°° °°°°°°°
Echo °°°°°°°°² °²°°°°°°°°°°²° °°°°°°°°°°°°°°
Echo ² °°°°°°° °°°°°°°°°°°°°° °°°°° ³³°°°°°°°°°°°°°
Echo ³°°°°°°°°°°² ³°°°°°°°°°°°° ³°°°°°°°°°°°°°°°°°°
Echo ³°°°°° °°°°° ³°°°°°°°°°°°°° °°°°°°°°°³°°°°°°°°°
Echo °°°°°°° °°°° ° °²°°°°°°°°°°³ ²°°°°°°°°°° °°°°°°°°°°°
Echo ²°°°°°°°°°°°° ° °°°°°°°° °°°°°° ² °°°° °°°°°°°°° °
Echo °°°°°°°°°°°°° ° °°°°°°°°°°°°°°°²°°° °°° °°°°°°°°° °°°
Echo °°°°°°°°°° °°°°°°°° °°°°°°°°°²°°°² °°°°°°°°° °°°°²
Echo °°°°°°³³°°°°°°°° °°°°°°°°°°°°°°°°°°°°°°°°²°°°°°°
Echo ²°°°°° °°°°° °°³°°°°°°²°°°°°°°²°²°°°°°° °°°°°°°°
Echo °°°°°° ³°²°°°°°°°°°°°°°°°°°° ²°°°°° °°°°°°°°³
Echo ² °°°°°²°°°°°°°°°°°°°°°°°°° °°°° °°°°²°°°°°°
Echo °²°°² °°°°²°°°°°°°°°°°°°°°³ °°°²°°³°°°°°°°°°°°°
Echo °°°°°° °°°°°°°°°°°° °°°² °°°°°°° °°²°°°°°²°°°°°
Echo °°°°°°°² °°°°°°°°° °°°°²°°°°°°°° °°°°°°° °°°°°°°
Echo °°°°°°°²°²³³°°°°°°°°°°°°°°°°²°°³ °°°² °°°°°°°°
Echo °°°°°°°°°°°°°°°°°°°°°°° ° ° °°° °°°°°°°°°°°°
Echo °°³³³°°°°°°°°°°°°°°°°° ²° °°°°°°°°°°°°°°°°°
Echo °°°°°°°°°°°°°°°°°°°°° °²°°°°°°°°°°°°°°°²
Echo °°°°°°°°°°°°°°°°°°°°° °°°°°°°°°°°°°°°
Echo ³°°°°°³°°°°°°° °°°°°° °°°°° °°°°°°°°°°°
Echo ° °° ³°°°° °°°°°² °°°° °°°°°°°°°°°
Echo ³ ²² ² °°°° °°°°°°°°°°²
Echo ° °°°°°° °°°²°°³°°°°°°°°°°³
Echo °² ³°°°° °° ° °³°°°° ³³°°°° °
Echo ²° °°°°°° °°°³°°°° °²°°°°°°°°°°² °°°°°
Echo °° ° ° ²²²²°²°°°°°°°°°°°°°°³ °°°°°°°²
Echo ²°²° °°°²° ²³°°°°° °°²°°°² ²°°°°°°°²
Echo °°°°°°³° ² ³°°°°°°° ³²°²°°° °°°°°
Echo ° ²° ²° ° °°²°°³ °°°°°°°°² °
Echo ° °° ° ° ° ³°°° °° °°°°°°°°²
Echo °°° ° ° °°°°° °°°° °°° °°°°°°°°°
Echo °°°°°°°°°²°°°°°°°°°° °° ° °°°°°°°°°°
Echo °°°°°°°°°°°°°°°°° °²°°°²² ³°°°°°°°°°
Echo °°°°°² °°°°°°°°°°²³²°°°°²³ °°°°°°°°°°
Echo ²°°°°°°³° °³²°°°°° °°° ° °° °°°°°°°°°°
Echo °°°°°°°°°²° ° ° ° ° °³°³ °³°² ³°°°°°°°°°°
Echo ²°°°°°°°° ° ° ° °°°°°° ²°²°°° ³³³ °°°°°°°°°°°°°°°°²
Echo ²°°°°°°°°°°°°° ° ° ° °° °°°°°°³ °°²°°°°°°°°°°°°°
Echo ²°°°°°°°°°°°°°° °°°°°°³°°°°°² ² ²°°°°°°°°°°°³
Echo °°°°°°°°°°°° ° ° ³ °° °° °°°°°°° °°°°°°°°°°°
Echo °°°°°°°°°°°° ³ ° °°²° ³ ° °°°°°°°° °°°°° °°°°
Echo °°°° ³°°°°° °²°°°° ° °° ³°°°°°°°° °°°°°°° °
Echo °° °°°°°°° °°°°°°² °°°°°°°°°°°°² °°°°°°°³
Echo °°°°°°°° °°°°°°°°°°°°°°°°°°°°° °°°°°°°°
Echo °°°°°°°° ²°°°°°°°°°°°°°°°°° °°°°°°°
Echo °°°° °°° ²°°°°°°°°°° ²²
pause
Mar 20, 2012. 12:50 AMPufferfish2584 says:
You guys are a bit silly. Honestly, a ping command is fairly simple, it sends a packet of data to a server to see if the server exists or your computer can reach it. For example, if you wanted to test your internet connection you could type ping www.google.com, which would send a packet of 64bytes to google, which would then reply which would look something like this:
C:\Users\Pufferfish>ping www.google.com

Pinging www.l.google.com [74.125.237.115] with 32 bytes of data:
Reply from 74.125.237.115: bytes=32 time=161ms TTL=56
Reply from 74.125.237.115: bytes=32 time=183ms TTL=56
Reply from 74.125.237.115: bytes=32 time=206ms TTL=56
Reply from 74.125.237.115: bytes=32 time=230ms TTL=56

Ping statistics for 74.125.237.115:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 161ms, Maximum = 230ms, Average = 195ms
So what it has done is connected to google, and google has replied.
The most chance you have with a ping command is the following command:
ping www.website.com -n 100 -l 65000 -i 250 -v FRAGMENT -4
Now what the -n does is sends 100 pings to the website
The -l sets the size, the maximum size is 65000 bytes, in order to crash a website you need more bytes than this, look up PING OF DEATH, but if your using CMD PROMPT this is the best you will get.
The -i is the time to live, so once it connects to the server it will keep the 65000 bytes for 250 seconds, this is the maximum ttl, which again is nowhere near enough to crash a website.
The -v command sets the type. What FRAGMENT does is tells the website to combine the ping at the server so it is 65000 bytes * 100.
and finally the -4 command tells it to use an IP version four gateway to the website, which is much more effective than IPV6.
!!! THIS IS NOT EVEN CLOSE ENOUGH POWER TO TAKE DOWN A WEBSITE, as Shomakerlev9 said earlier, the only way is with a DDOS which floods the website with so many pings it will not provide service to other computers. This is ilegal so dont do it! All this does is a DOS, so it is not powerfull enough to take down a website, but if you are on a work or school network and type in netstat, then instead of the website put in some of the connection names like, Pufferfish-Tank:49218 without the :49218, you can succesfully SLOW someones internet down.
///If you want any cool batch files made, for almost anything, just ask me and I may be able to help///
Dec 30, 2011. 8:10 PMShoemakerleve9 says:
All of you asking about the site crasher: What the file does is ping the website repeatedly, or as fast as your computer can handle. When it does this, all that happens is that the computer sends packets of data to the site, using (slowly using*) up its bandwidth. It will never probably crash it. But, if you really want to crash a site, search for "DDOS Attacks" on Google. I'm not going to go into that that much, but it's (very?) illegal. DDOSing, that is. Pinging are like little baby flies.
Dec 14, 2011. 8:06 AMMr.Butters53 says:
hi i do not understan how it works could you pleas explane
Mar 29, 2011. 11:53 PMRyan McDougall says:
I tryed the Web Site Crasher and it did not Crash the website

please help

thanks
Apr 18, 2011. 11:00 PMxana says:
i need a ip crasher version of this.
Jun 8, 2011. 6:52 PMttharp says:
How long does it take to crash?
May 16, 2011. 11:53 AMbdblock94 says:
and opens intenet explorer at the same time?
May 16, 2011. 11:52 AMbdblock94 says:
is there any way i could program this so that it crashes a set website as soon as it is opened?
May 5, 2011. 1:43 PMPANTHERSFAN17 says:
Does this code just have to be copied and pasted? Because it doesnt work for me
Apr 18, 2011. 1:33 AMmichaelb958 says:
This is not a very good batch file. Misuse of the IF command ("x==" and "x y" are not valid, and both should be "x==y"), redundant clearing of variables (seriously, if a blank response is given to "set /p" you get a blank variable, and setting to null beforehand helps with nothing else), and the redundant exit label (honestly, just invoke EXIT yourself, saves keystrokes) all need cleaning.
May 1, 2011. 2:31 AMmichaelb958 says:
In simpler terms: fix the IFs and the SETs. The if command works like "if x==y". And the first time you set a variable, give it a value.

P.S. Those passwords probably aren't that memorable, which largely defeats the purpose. (And be careful where you write those passwords down. I've heard of people who write the things on Post-it Notes and stick them to their computer monitors.)
P.P.S I'm only 14 and a half myself.
Apr 28, 2011. 11:09 PMRyan McDougall says:
what was the website you killed
Mar 2, 2011. 2:59 PMzazenergy says:
Cool!

Pro

Get More Out of Instructables

Already have an Account?

close

All Steps Viewing
View all steps of an Instructable on the same page when you're a Pro Member.

Upgrade to Pro today!
6
Followers
1
Author:radame(My youtube)
I am a computer "nerd" and I admit it...but if you see me on the street you will not know it...:)