Search

Showing posts with label Wi-Fi. Show all posts
Showing posts with label Wi-Fi. Show all posts

Tuesday, March 1, 2011

How to Crack a Wi-Fi Network’s WEP Password with BackTrackHow to Crack a Wi-Fi Network’s WEP Password with BackTrack

Today we're going to run down, step-by-step, how to crack a Wi-Fi network with WEP security turned on. But first, a word: Knowledge is power, but power doesn't mean you should be a jerk, or do anything illegal. Knowing how to pick a lock doesn't make you a thief. Consider this post educational, or a proof-of-concept intellectual exercise.
Dozens of tutorials on how to crack WEP are already all over the internet using this method. Seriously—Google it. This ain't what you'd call "news." But what is surprising is that someone like me, with minimal networking experience, can get this done with free software and a cheap Wi-Fi adapter. Here's how it goes.

What You'll Need

How to Crack a Wi-Fi Network's WEP Password with BackTrackUnless you're a computer security and networking ninja, chances are you don't have all the tools on hand to get this job done. Here's what you'll need:
  • A compatible wireless adapter—This is the biggest requirement. You'll need a wireless adapter that's capable of packet injection, and chances are the one in your computer is not. After consulting with my friendly neighborhood security expert, I purchased an Alfa AWUS050NH USB adapter, pictured here, and it set me back about $50 on Amazon. Update: Don't do what I did. Get the Alfa AWUS036H, not the US050NH, instead. The guy in this video below is using a $12 model he bought on Ebay (and is even selling his router of choice). There are plenty of resources on getting aircrack-compatible adapters out there.
  • A BackTrack 3 Live CD. We already took you on a full screenshot tour of how to install and use BackTrack 3, the Linux Live CD that lets you do all sorts of security testing and tasks. Download yourself a copy of the CD and burn it, or load it up in VMware to get started. (I tried the BackTrack 4 pre-release, and it didn't work as well as BT3. Do yourself a favor and stick with BackTrack 3 for now.)
  • A nearby WEP-enabled Wi-Fi network. The signal should be strong and ideally people are using it, connecting and disconnecting their devices from it. The more use it gets while you collect the data you need to run your crack, the better your chances of success.
  • Patience with the command line. This is an ten-step process that requires typing in long, arcane commands and waiting around for your Wi-Fi card to collect data in order to crack the password. Like the doctor said to the short person, be a little patient.

Crack That WEP

To crack WEP, you'll need to launch Konsole, BackTrack's built-in command line. It's right there on the taskbar in the lower left corner, second button to the right. Now, the commands.
First run the following to get a list of your network interfaces:
airmon-ng
The only one I've got there is labeled ra0. Yours may be different; take note of the label and write it down. From here on in, substitute it in everywhere a command includes (interface).
Now, run the following four commands. See the output that I got for them in the screenshot below.

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

How to Crack a Wi-Fi Network's WEP Password with BackTrack If you don't get the same results from these commands as pictured here, most likely your network adapter won't work with this particular crack. If you do, you've successfully "faked" a new MAC address on your network interface, 00:11:22:33:44:55.
Now it's time to pick your network. Run:
airodump-ng (interface)
To see a list of wireless networks around you. When you see the one you want, hit Ctrl+C to stop the list. Highlight the row pertaining to the network of interest, and take note of two things: its BSSID and its channel (in the column labeled CH), as pictured below. Obviously the network you want to crack should have WEP encryption (in the ENC) column, not WPA or anything else.
How to Crack a Wi-Fi Network's WEP Password with BackTrack Like I said, hit Ctrl+C to stop this listing. (I had to do this once or twice to find the network I was looking for.) Once you've got it, highlight the BSSID and copy it to your clipboard for reuse in the upcoming commands.
Now we're going to watch what's going on with that network you chose and capture that information to a file. Run:
airodump-ng -c (channel) -w (file name) --bssid (bssid) (interface)
Where (channel) is your network's channel, and (bssid) is the BSSID you just copied to clipboard. You can use the Shift+Insert key combination to paste it into the command. Enter anything descriptive for (file name). I chose "yoyo," which is the network's name I'm cracking.
How to Crack a Wi-Fi Network's WEP Password with BackTrack

You'll get output like what's in the window in the background pictured below. Leave that one be. Open a new Konsole window in the foreground, and enter this command:
aireplay-ng -1 0 -a (bssid) -h 00:11:22:33:44:55 -e (essid) (interface)
Here the ESSID is the access point's SSID name, which in my case is yoyo. What you want to get after this command is the reassuring "Association successful" message with that smiley face.
How to Crack a Wi-Fi Network's WEP Password with BackTrack
You're almost there. Now it's time for:
aireplay-ng -3 -b (bssid) -h 00:11:22:33:44:55 (interface)
Here we're creating router traffic to capture more throughput faster to speed up our crack. After a few minutes, that front window will start going crazy with read/write packets. (Also, I was unable to surf the web with the yoyo network on a separate computer while this was going on.) Here's the part where you might have to grab yourself a cup of coffee or take a walk. Basically you want to wait until enough data has been collected to run your crack. Watch the number in the "#Data" column—you want it to go above 10,000. (Pictured below it's only at 854.)
Depending on the power of your network (mine is inexplicably low at -32 in that screenshot, even though the yoyo AP was in the same room as my adapter), this process could take some time. Wait until that #Data goes over 10k, though—because the crack won't work if it doesn't. In fact, you may need more than 10k, though that seems to be a working threshold for many.
How to Crack a Wi-Fi Network's WEP Password with BackTrack

Once you've collected enough data, it's the moment of truth. Launch a third Konsole window and run the following to crack that data you've collected:
aircrack-ng -b (bssid) (file name-01.cap)
Here the filename should be whatever you entered above for (file name). You can browse to your Home directory to see it; it's the one with .cap as the extension.
If you didn't get enough data, aircrack will fail and tell you to try again with more. If it succeeds, it will look like this:
How to Crack a Wi-Fi Network's WEP Password with BackTrack The WEP key appears next to "KEY FOUND." Drop the colons and enter it to log onto the network.

Problems Along the Way

With this article I set out to prove that cracking WEP is a relatively "easy" process for someone determined and willing to get the hardware and software going. I still think that's true, but unlike the guy in the video below, I had several difficulties along the way. In fact, you'll notice that the last screenshot up there doesn't look like the others—it's because it's not mine. Even though the AP which I was cracking was my own and in the same room as my Alfa, the power reading on the signal was always around -30, and so the data collection was very slow, and BackTrack would consistently crash before it was complete. After about half a dozen attempts (and trying BackTrack on both my Mac and PC, as a live CD and a virtual machine), I still haven't captured enough data for aircrack to decrypt the key.
So while this process is easy in theory, your mileage may vary depending on your hardware, proximity to the AP point, and the way the planets are aligned. Oh yeah, and if you're on deadline—Murphy's Law almost guarantees it won't work if you're on deadline.

Thursday, September 2, 2010

6 useful Wi-Fi tools for Windows

Free or cheap apps can help troubleshoot your wireless network, turn your laptop into a hot spot and more

We live in a mobile world; if you have a laptop (and who doesn't?), that means constantly connecting to the Internet via Wi-Fi. You most likely use Wi-Fi not just when you're on the road at cafés, airports or hotels, but to connect to your home network too. You might even connect to a wireless network at the office. Here's the problem: Windows doesn't do a particularly good job of providing Wi-Fi tools. Yes, it will let you search for and connect to nearby networks, but that's about the extent of it. What if you want to get detailed information about every Wi-Fi network within range, troubleshoot your network, turn your laptop into a portable Wi-Fi hot spot or keep yourself safe at public hot spots? Windows is no help.
That's why we've rounded up these six downloads. They'll do all these things and more. Five out of the six are free; the other is inexpensive and lets you try it out first.

InSSIDer

MetaGeek's InSSIDer is a great tool for finding Wi-Fi networks within range of your computer and gathering a great deal of information about each. It's also useful for troubleshooting problems with your own Wi-Fi network.
For every Wi-Fi network InSSIDer finds, it shows you the MAC address of the router, the router manufacturer (if it can detect it -- it usually does), the channel it's using, the service set identifier (SSID) or public name of the network, what kind of security is in place, the speed of the network and more. In addition, it displays the current signal strength of the network, as well as its signal strength over time.
InSSIDer
InSSIDer finds a great deal of information about nearby wireless networks and reports on what it finds.
How would you use the software to troubleshoot your wireless network? If you see that your network uses the same channel as nearby networks with strong signals, you'll know that you should change the channel your network transmits over and thereby cut down on potential conflicts. (Most routers have a settings screen that lets you do this.)
You can also use the software to detect "dead zones" that don't get a strong Wi-Fi connection. Walk around your home or office with InSSIDer installed on your laptop to see where signal strength drops. You can either avoid using a computer in those spots or else try repositioning the wireless router to see if it helps with coverage.
Whether you need to troubleshoot a network or find Wi-Fi hot spots to which you want to connect -- or you're just plain curious -- this is one app you'll want to download and try.
Price: Free
Compatible with: Windows XP, Vista and 7 (32- and 64-bit)
Download InSSIDer

Xirrus Wi-Fi Inspector

This is another excellent program that sniffs out Wi-Fi networks and shares pertinent information about them, such as how close or far away they are. Xirrus Wi-Fi Inspector shows any nearby hot spots on a radar-like display. A separate pane offers detailed information about every hot spot it finds, including signal strength, the kind of network (802.11n, for example), the router vendor, the channel on which the network transmits and whether it's an access point or an ad hoc network.
In a pane next to the radar, Wi-Fi Inspector shows you even more detailed information about the network to which you're currently connected, including your internal IP address, external IP address, DNS and gateway information, and so on.
Xirrus Wi-Fi Inspector
Xirrus Wi-Fi Inspector uses a radar-like interface to show you information about nearby hot spots.
Why use Xirrus Wi-Fi Inspector rather than MetaGeek's InSSIDer? Wi-Fi Inspector's simpler, cleaner layout makes it easier to see information about all of the hot spots at a glance. It also shows the relative physical distance between you and each hot spot on its display. And there's no denying the overall coolness factor of a radar-like display.
However, if you want more detailed information, including the relative signal strengths of all nearby wireless networks, InSSIDer is a better bet.
Price: Free
Compatible with: Windows XP SP2+, Vista and 7
Download Xirrus Wi-Fi Inspector

Connectify

This very nifty piece of free software lets you turn a Windows 7 PC (it only works with Windows 7) into a Wi-Fi hot spot that can be used by nearby devices -- your smartphone, for example, or devices that your co-workers are using in the same location.
Connectify
Connectify turns your laptop into a mobile Wi-Fi hot spot.
The PC on which you install it will, of course, need to be connected to the Internet itself and have Wi-Fi capability so it can provide access to other devices. The computer doesn't necessarily need a wired connection to the Internet (although it won't hurt to have one); its Wi-Fi card can perform double-duty as Wi-Fi signal receiver and transmitter.
Setting up a hot spot is simple: Once you have a connection, run Connectify on your PC and give your hot spot a name and password. Your computer's Wi-Fi card will begin broadcasting a Wi-Fi signal that other devices can connect to, in the same way they can connect to any other hot spot. (Your PC card will broadcast in whatever Wi-Fi protocol it was built for. It also should support devices that use earlier protocols -- for example, an 802.11n signal should allow 802.11b/g/n devices to connect.)
Since your hot spot is password-protected, only people who know the password can use it; the signal is secured with WPA2-PSK encryption.
You can even use Connectify to set up a local network without an external Internet connection. Run it as a hot spot, and nearby devices can connect to each other in a network, even though there's no Internet access. You can use this for sharing files in a workgroup or setting up a network for multiplayer games.
Note that I had problems connecting my Mac to a Windows 7 machine running a Connectify-created hot spot, but I was able to make the connection with other PCs and devices.
Price: Free
Compatible with: Windows 7
Download Connectify

WeFi

Tools like InSSIDer and Xirrus Wi-Fi Inspector are great for finding hot spots that are currently in range of your laptop. But if you want to find hot spots in other locations -- a part of town that you'll be in later in the day, for example, or a city you'll be visiting next week -- you'll want to give WeFi a try.
Like other Wi-Fi sniffing tools, WeFi uses your Wi-Fi card to find your current location and show you nearby hot spots. You can click on a link to see a particular hot spot on a map, along with its address. (Note, however, that in practice I found it was not always accurate.)
But you can also type in a different location to see hot spots near that location. Click the Wi-Fi Maps tab and enter an address; a map of that location will appear on Google Maps and you'll be provided with various details about nearby hot spots, such as type (municipal, hotel, café and so on), distance from the location and whether there's an access fee.
WeFi
WeFi helps you find hot spots both near your computer and in other locations.
WeFi also helps you manage how to connect to hot spots. It can, for example, automatically connect you only to your favorite hot spots or only to hot spots that have been discovered by other WeFi members.
The basic version of WeFi is free, but there's also a version called WeFi Premium that you have to pay for. WeFi Premium finds and connects you to paid hot spots. The amount you pay for WeFi Premium varies depending on whether you want to pay an hourly rate, prepay for a certain number of minutes and so on. You'd be better off skipping WeFi Premium; it's much easier to find paid hot spots on your own.
Price: Free
Compatible with: Windows XP, Vista and 7
Download WeFi

Hotspot Shield

When you connect to the Internet via a public hot spot, you put yourself at risk because someone might try to sniff your packets or otherwise snoop on what you're doing online. Hotspot Shield, a free, lightweight piece of software from AnchorFree, promises to keep you safe by creating a secure VPN connection and encrypting all of your communications.
Hotspot Shield
Hotspot Shield lets you use a VPN to protect yourself while using a public hot spot.
As you connect to a hot spot, simply run Hotspot Shield, and it will begin protecting you using the HTTP Secure (HTTPS) protocol. It launches a tab to show you that you're connected; to disconnect, click the Disconnect button on the tab. To connect again, click the Connect button. You can also connect and disconnect by right-clicking the program's icon in the System Tray.
You'll need to take some care when you first install Hotspot Shield. If you don't want its toolbar installed in your browser, uncheck the box next to "Include the Hotspot Shield Community Toolbar." Also, make sure to uncheck the boxes for setting Hotspot Shield Private Search as your default search, setting your home page to the Hotspot Shield Private Search page, fixing "Page Not Found" errors, and enabling you to get instant alerts from the software -- those options won't do you much good and will likely annoy you.
A few caveats: When you run the software, it will open a browser tab to the product's home page, which has ads on it. You can close that tab if you want; the program works fine without it open. Also, according to a page on the Hotspot Shield Web site, you might see targeted ads appear above Web pages you visit. That hasn't happened to me, although I've seen complaints elsewhere around the Web about intrusive ads. Finally, some people who have downloaded the program have complained that it is unstable, or they were unable to uninstall it. In my tests I didn't run across those problems, but be forewarned that others have reported them.
While AnchorFree offers Hotspot Shield for free, other companies sell similar VPN software products to protect you at public hot spots. ConnectInPrivate, for example, offers software and a service that costs $14.99 per month.
Price: Free
Compatible with: Windows 2000, XP, Vista and 7 (also Mac OS X 10.4, 10.5 and 10.6)
Download Hotspot Shield

Plug and Browse

If you use your laptop to connect to more than one wireless or wired network, you might be spending more time than you'd like switching network settings.
For example, if you're a typical notebook user, at work you might have a static IP address, a default network printer, a set of scripts that need to be run, proxy servers for security and a set of mapped network drives. At home, you might have a DHCP-assigned network address on a wireless network as well as a home printer, and you might use Windows Firewall but no proxy servers. And then there's that coffee shop hot spot that you visit regularly with its own set of requirements, such as a DHCP-assigned network address.
Each time you switch networks, chances are that you have to tweak settings such as your default printer, mapped network drives, proxy servers and so on.
Plug and Browse from Interactive Studios puts an end to all that manual configuration. It allows you to create profiles for all the networks you use, and then when you switch from one network to another, you simply choose the new network's profile. All your settings will be intact.
Plug and Browse
Plug and Browse makes it easy to switch among multiple networks, including Wi-Fi-based ones, without having to go through constant configurations.
A very nice touch is that you can tell Plug and Browse to automatically create a profile for you and it will grab all of your current settings for the network to which you're connected. You can still edit the settings after that if you need to.
Price: $39.99 (with 30-day free trial)
Compatible with: Windows XP, Vista and 7
Download Plug & Browse
Preston Gralla is a contributing editor for Computerworld.com and the author of more than 35 books, including How the Internet Works (Que, 2006).
Read more about Wireless Networking in Computerworld's Wireless Networking Topic Center.

Friday, June 18, 2010

Google Wi-Fi data grab snared passwords, e-mail

Google claims it picked up only 'fragments' of personal data


Wi-Fi traffic intercepted by Google's Street View cars included passwords and e-mail, according to the French National Commission on Computing and Liberty (CNIL).
CNIL launched an investigation last month into Google's recording of traffic carried over unencrypted Wi-Fi networks, and has begun examining the data Google handed over as part of that investigation.
Google revealed on May 14 that the fleet of vehicles it operates to compile panoramic images of city streets for its Google Maps site had inadvertently recorded traffic from unencrypted Wi-Fi networks. Google's intention was only to record the identity and position of Wi-Fi hotspots in order to power a location service it operates, the company said. However, the software it used to record that information went much further, intercepting and storing data packets too.
At the time, Google said it only collected "fragments" of personal Web traffic as it passed by, because its Wi-Fi equipment automatically changes channels five times a second. However, with Wi-Fi networks operating at up to 54M bits per second, it always seemed likely that those one-fifth of a second recordings would contain more than just "fragments" of personal data.


That has now been confirmed by CNIL, which since June 4 has been examining Wi-Fi traffic and other data provided by Google on two hard disks and over a secure data connection to its servers.
"It's still too early to say what will happen as a result of this investigation," CNIL said Thursday.
"However, we can already state that [...] Google did indeed record e-mail access passwords [and] extracts of the content of e-mail messages," CNIL said.
Data protection authorities in Spain and Germany have also asked Google for access to Wi-Fi traffic data intercepted in their countries, but the CNIL was the first to have its request granted, it said.
Google also told CNIL that the data collected by the Street View cars is also used by other services, including Google Maps and Google Latitude, which allows users automatically transmit their location to friends, and to track others who choose to share their location via the service.
That's of interest to CNIL, because Google has still not made the necessary statutory declarations regarding its processing of personal data for the Latitude service in France.