How to Hack Wireless Network

>> Tuesday, January 10, 2012

It is easy to hack wireless networks if the proper security measures are not in place. If your wireless network is compromised you can be liable for any illegal activity on it. There are numerous stories of child pornographers and black-hat hackers using other peoples wireless networks.

                                   Hack WEP

  • We need a Computer/Laptop. 
  • A Wireless Card capable of packet injection. If your laptop wireless card can't do packet injection you can purchase a wireless adapter such as the Netgear WG111 v2 for around $8-$12 on eBay. 
  • A Live installation of BackTrack either on a CD or USB stick.

You can download BackTrack 5 Here and Create a Live USB Install Here.

WEP is the predecessor of WPA and has been hacked for the past 5+ years yet people continue to use it. With the instructions below we can crack WEP in under 15 minutes.

You can crack WEP from the command line but there is an easy GUI interface in backtrack which makes it a much less painful experience for those who are scared of command prompts.
Boot into BackTrack
Click on the Backtrack applications menu -> Backtrack -> Exploitation tools -> Wireless exploitation -> WLAN Exploitation -> gerix-wifi-cracker-ng.
Go to the configuration menu and select the wireless interface wlan0
  -Click on Enable/Disable Monitor Mode (this will put the wireless card into monitor mode).
  -Select the newly created mon0 interface.
Now click on the WEP tab at the top of the window.
  -Click on "Start sniffing and logging" and leave the terminal open.
  -Once the wireless network you want to crack* shows up (it has to be WEP encryption of course) select the WEP Attacks (with clients). *note that the PWR has to be high enough to work so the closer you can get, the better.
  -There you click on “Associate with AP using fake auth”, wait a few seconds and click on “ARP request replay”.
Once the Data number reaches over 10,000 you are ready to try (if the data is coming fast wait until 20 or 30,000 to be safe) and crack the key, but don't close any windows yet.
  -Go to the cracking tab and click on “Aircrack-ng – Decrypt WEP password” under Wep Cracking.

It will take a few seconds to minutes to crack the password and then you are good to go.

At least WPA and WPA2 are safe right? Wrong. WPA and WPA2 are both crackable but the time it takes to crack depends on the strength of their password.

                                  Hack WPA/WPA2

-Boot into BackTrack
-Open up Konsole which is a command line utility built into BackTrack. It is the Black Box in the Lower-Left Hand Corner.

-The following commands stop the wireless interface so you can change your mac address, this is important because your mac address is a unique identifier so faking one is a good idea if you are accessing a network you don't have permission to. (which by the way I wholly condemn)

airmon-ng stop wlan0
ifconfig wlan0 down
macchanger --mac 00:11:22:33:44:55 wlan0
airmon-ng start wlan0

-Now we will put the airodump-ng tool into monitor mode, this will allow us to see all of the wireless networks around us.

airodump-ng mon0

Now choose the network you want to hack and take note of the BSSID, and the Channel it is one as well as the ESSID. The PWR has to be fairly high to be able to hack it, this is determined by how close you are to the wireless router. The closer you are, the better.

Once you have chosen the wireless network enter the following into the terminal:
This will write capture packets and put them into the "filename" file, we are trying to capture the handshake between the router and wireless connection which will give us the key we need to crack.

airodump-ng mon0 --channel * --bssid **:**:**:**:**:** -w filename

The following step is optional but is highly recommended as it will speed up the process a great deal.

Once “WPA handshake: **:**:**:**:**:**” appears in the top right-hand corner we can move on. If you are having trouble getting the WPA handshake to occur then do step 4.

aireplay-ng -0 1 -a **:**:**:**:**:** -c **:**:**:**:**:** mon0

What this step (4) does is it deauthorizes a wireless connection and trie to re-establish it so it will generate a new handshake to capture. This step ends once you have captured the handshake.

aircrack-ng –w wordlist.lst -b **:**:**:**:**:** filename.cap

Step 5 is now trying to crack the password in "filename.cap" using a list of words, here called "wordlist.lst" you can download a good 200 million word dictionary here (128MB but unzipped is 800MB).

Your computer has to compute the hash value of every password in that list but a computer can go through those 200 million passwords in 6-12 hours.


If the password isn't found in the dictionary you can try and brute-force the password with this command: (Note this could take a very long time depending on their password strength).

/pentest/password/jtr/john --stdout --incremental:all | aircrack-ng -b **:**:**:**:**:** -w - filename.cap

blog comments powered by Disqus

Post a Comment

Related Posts with Thumbnails

  © Blogger template Webnolia by 2009

Back to TOP