Batch WI-FI Brute Forcer

This project is based upon the trick that, how to hack WI-FI with CMD. The main purpose behind, creating wifi hacking tool with cmd tool is to make everyone aware that how easy it is to break a simple password. And, motivate them to keep some complex passwords – to keep them protected against it.


Some of you may know the concept of Brute Forcing, but I will explain it for the ones who don’t know. In case, you are already familiar with it – you are free to skip this part (although, you will definitely learn something new from it).

There are 3 types of attacks:


This type of attacks are simply try all possible combinations. And, it seems weird and impractical at first. But, as computers can do billion of calculations per second – so, it is not that much impractical to try out everything. The only problem is – it needs time; HELL LOT OF TIME!


In this type of password hacking attack – again we try all passwords, but this time they are stored in a text file that you have given to the program. So, the program only refers to a few password combinations to verify the accessibility of the network.


In masked attack; we apply a bit different approach – Here the concept is to try all possible combinations in a way programmer defines. And, in this attack hackers combine some social engineering to make it better and less hard for the dumb computer.


So, basically – In this part, you’ll know how it is possible to hack wifi password with CMD and it is not another fake trick to fool you guys! Let’s have a look at the basic parts of this main project:

WI-FI Brute Forcer has 3 main parts:

  1. Interface Detection and Selection
  2. WI-FI Scanning
  3. Attacking

Detecting Interfaces and Selection

netsh wlan show interfaces

With the help of built-in executable netsh.exe, so many things are possible. Program detects your physical interfaces with the command above but not by just simply running it, by a very advanced for loop which batch scripts provide that is something I love about CMD(Versatile for loops). With this for loop, interfaces are being enumerated and stored inside the global variables. Selection is up to you from this time if you have multiple interfaces. Program will choose the only option if you have just 1.


netsh wlan show networks

Netsh means so much if you consider networking with CMD. Above command is technically shows us which networks can be seen from which interfaces. The tricky loops of CMD come to play again. Algorithm enumerates every network and stores them in a file which will be printed onto the screen.


netsh wlan connect name="<SSID>" interface="<WI-FI>"

A simple command turned a script into a hacking machine. The command above just connects to a network if you use it singular. The trick under the hood is using it in a loop until a sign of connection occurs between you and the router. The program checks the connection status while running the command above so if you are connected, than the attack is successful.

How Password Lists Are Being Used Inside The Script?

Short answer: XML and String Substitution.

The method which Windows uses to connect a network is using an XML file to store SSIDs and passwords. The program is using a modified XML file to create custom importable XML files. There are placeholder texts where normal SSIDs and passwords should be.

When you select a network from a scan result, the script changes the “changethistitle” text with the selection of yours as you can see above. Then a big loop of password usage starts. The script takes the passwords from the passlist.txt one by one and basically changes the “changethiskey” text with this password. Then the script imports the XML file with CMD command below.

netsh wlan add profile filename=attempt.xml

With this import, now we are ready to try connecting. Rest of it is the job of connection command of netsh.

Brute Forcer In Action – From The Creater: TUX


I have provided you a key combinator app that can create random passwords with the information you gave.



11 thoughts on “Batch WI-FI Brute Forcer

  1. Hello Old Friend, As always – Perfect Work. your creation is amazingly awesome.

    I can see, you have a big potential for the future. I hope to see more amazing projects like these from your side. Please also add a link to your website in the article. so, people can see your other creations as well and know you more closely via your work.

  2. Great application of the Windows tools. There are very few Windows programs that make it as easy as this. The only recommendations I have are as follows:

    1. Investigate the posibility of using multiple interfaces at once (multiple cmd windows).
    2. Investigate the posibility of downloading and utilizing word lists from github

    Thanks for sharing this script with us!

    1. Yes, i also had similar ideas. (great minds think alike)

      @TechnicalUserX you can actually, put a wordlist on Your Github, and use Batcenter to download it in the system. (before Wifi-brute-forcer disconnects from the currently connected WIFI network)

      And run multiple instances of CMD to scan – that might increase the speed of the scan tremendously. 🙂

      1. @Kvc, that would be brilliant, but as I said, I am moving to the C/C++ and will probably write programs in them for very advanced stuff. Maybe at that time, a version 2.0 of Brute Forcer will be released! Who knows? 😜

    2. SetLucas, thanks for your beautiful feedback. I understand your what you mean by those possibilities but I virtually do not use batch for very advanced programs nowadays. Let’s not say I will not investigate those possibilities, I will probably code them in C/C++ in the future. 😀

Leave a Reply