Authorized use only. This tool is for recovering YOUR OWN forgotten passwords only. Unauthorized network access is illegal.
Cryptography Explained

WPA3 Dragonfly Handshake — SAE Explained

The Simultaneous Authentication of Equals (SAE) handshake, specified in IEEE 802.11-2016 and commonly called Dragonfly (RFC 7664), is the foundation of WPA3 security. It replaces WPA2's directly PSK-derived PMK with a password-authenticated key exchange that never reveals the password over the air — the 4-way EAPOL handshake still runs afterwards, now keyed by the SAE-derived PMK. Understanding SAE at the cryptographic level is essential for anyone working in WiFi security, password recovery, or network auditing — because the protocol change eliminates the most common attack vector (offline handshake cracking) and fundamentally shifts the WiFi security landscape. This article explains the Dragonfly handshake in detail, covering the mathematical operations, protocol messages, anti-clogging mechanism, and what it means for password recovery in 2026.

Why WPA2's 4-way handshake was replaceable

The WPA2 4-way handshake served two purposes: (1) prove that both parties know the PSK without transmitting it directly, and (2) derive fresh session keys (PTK, GTK) for encrypting data traffic. However, the handshake frames contained sufficient information for an offline dictionary attack — the MIC (Message Integrity Code) is a keyed hash that can be verified against candidate PSKs.

The attack works because the PMK (Pairwise Master Key) is derived deterministically from the PSK and SSID through PBKDF2. An attacker captures the Anonce, Snonce, and MIC from the handshake frames, then tests candidate passwords: for each password, compute PMK, derive PTK, check if the MIC matches. If it does, the password is correct.

This offline verification is possible because the handshake material is transmitted in plaintext (before encryption keys are established). The protocol was designed for mutual authentication but inadvertently exposed the PSK to offline verification — a structural weakness that SAE eliminates.

The fundamental SAE difference

In WPA2, the password is used as a shared secret that both parties prove knowledge of through a protocol that leaks verification material. In SAE, the password is used to derive a shared secret via a cryptographic commitment that cannot be verified offline. This is the difference between 'proving knowledge by revealing' and 'proving knowledge by concealing.'

SAE protocol overview — two phases

Phase 1 (the SAE commit exchange): both the supplicant (client) and authenticator (AP) independently derive a Password Element (PWE) from the password and the peer MAC addresses through a hash-to-element or hash-to-curve operation. Each party generates a secret ephemeral scalar and a secret random mask, then transmits a Commit carrying commit-scalar = (rand + mask) mod r and commit-element = -(mask * PWE). The mask never leaves the device: it is what hides the ephemeral scalar and gives SAE its forward secrecy.

Phase 2 (the SAE confirm exchange): after receiving the peer's commit-scalar and commit-element, each party computes the shared secret K = sa * (peer_commit_scalar * PWE + peer_commit_element) — a scalar multiplication on the elliptic curve (ECC variant) or modular exponentiation (FFC variant). This produces a cryptographically strong shared secret K that both parties can independently compute.

After Phase 2, the shared secret K is used to derive the PMK through a KDF (Key Derivation Function). The PMK then feeds into the existing 802.11 key hierarchy (PTK derivation via PRF-384 or PRF-512) identical to the WPA2 post-PMK flow.

Password Element (PWE) derivation — hash-to-curve

The PWE is the critical link between the human-memorable password and the SAE protocol. WPA3 defines two derivation methods. In the newer Hash-to-Element (H2E) method — the standard method in current WPA3 — the SSID is the HKDF-Extract salt and the peer MAC addresses salt the final scalar. The older hunting-and-pecking method computes pwd-seed = HMAC-SHA256(MAX(addr) || MIN(addr), password || counter) — the salt is the two MAC addresses, not the SSID — and then applies a KDF with the fixed-info string 'SAE Hunting and Pecking', incrementing the counter until the result maps to a valid point on the curve.

H2E was adopted precisely because it is computationally efficient: it derives the element directly instead of iterating, and it resists the side-channel and group-downgrade weaknesses hunting-and-pecking had. The per-peer MAC salt in both methods is what stops an attacker precomputing PWE tables for an entire ESSID.

SAE's resistance does not come from the cost of PWE derivation — it comes from the protocol making a passive capture unverifiable. The Commits are masked with each peer's secret mask, so a purely passive eavesdropper has no check value against which to test a candidate, whatever hardware they own. Per-candidate work is small (one element derivation plus a few group operations) and parallelises freely, which is why attacks that involve the attacker in the exchange — rogue AP or side-channel assisted — are the practical threat rather than passive capture.

Elliptic curve vs finite field groups

SAE supports two underlying mathematical structures: Elliptic Curve Cryptography (ECC) and Finite Field Cryptography (FFC). ECC groups (defined by IANA and the Wi-Fi Alliance) include: 19 (256-bit random ECC, NIST P-256), 20 (384-bit ECC, NIST P-384), 21 (521-bit ECC, NIST P-521). FFC groups in the IANA Diffie-Hellman registry include: 1 (768-bit MODP), 2 (1024-bit MODP), 5 (1536-bit MODP), 14 (2048-bit MODP), 15 (3072-bit MODP).

In practice, WPA3 implementations use group 19 (P-256) by default. Groups 1 and 2 are disallowed because of the Dragonblood downgrade attacks (2019) — WPA3 rejects every MODP group below 3072 bits. WPA3-Enterprise 192-bit mode uses P-384 (IANA group 20), not group 21: it is an 802.1X/EAP-TLS mode and does not use SAE at all.

The group choice affects: (1) key size — P-256 produces 32-byte shared secrets vs P-521's 66-byte; (2) computational cost — P-256 scalar multiplication is substantially faster in practice than P-521 or MODP, though the exact ratio depends on the library and hardware; (3) post-quantum security — both ECC-based and FFC-based SAE fall to Shor's algorithm, which solves the discrete-logarithm problem in finite fields as well as on elliptic curves. No practical quantum attack exists in 2026.

Anti-clogging tokens and DoS protection

SAE includes a built-in denial-of-service protection mechanism: anti-clogging tokens. When the AP is under load it rejects the client's Commit with status code 76 (Anti-Clogging Token Requested) and supplies a token that the client echoes back in the retried Commit. The token is built from a temporary key plus the peer station's MAC address and is verified by recomputation — it is a per-client credential, not a puzzle, so a flooding attacker using random MAC addresses cannot produce one.

Because the token is bound to the sender's MAC address, an attacker cannot amortise one token across thousands of spoofed handshake attempts, which is what makes the mechanism effective against SAE flooding.

The anti-clogging mechanism does NOT affect legitimate authentication or password recovery — for the intended use of SAE (authenticating a known password) the client simply echoes the token back, and no computation is required of it.

Why SAE prevents offline cracking — the math

In WPA2, the PMK is directly verifiable: given a PSK candidate, compute PMK = PBKDF2(PSK, SSID) via 4096 iterations, use it to compute the PTK and verify the MIC from the captured handshake. This is a purely computational operation that can be done offline with zero interaction.

In SAE, a passive capture yields nothing verifiable. Each Commit carries a masked scalar and a masked element, and the shared secret K depends on the peers' secret ephemerals that the eavesdropper never sees — so there is no check value to test a candidate against, however much hardware is applied to the problem.

That is the difference from WPA2, where a captured handshake is a static check value a GPU can test at millions of candidates per second. SAE raises the cost of password recovery rather than making it free, but its protection against a purely passive capture is categorical rather than a matter of throughput.

WPA3 Transition Mode — the crackable exception

WPA3-Personal transition mode (an optional backward-compatibility mode — it is not permitted in 6 GHz, and WPA3 client devices are instead required to implement Transition Disable) allows both WPA3 (SAE) and WPA2 (4-way handshake) associations. The AP advertises both AKM suites in its RSN IE: AKM 00-0F-AC:8 (SAE) and AKM 00-0F-AC:2 (PSK). Clients may associate with either.

When a client associates via the WPA2 path, the complete 4-way handshake is transmitted — vulnerable to offline dictionary attack. Since both paths share the same password, cracking the WPA2 handshake reveals the WPA3 password as well.

A rogue AP broadcasting a WPA2-only network under the same SSID can capture a downgrade: some clients connect to it in WPA2 and expose the 4-way handshake (Dragonblood §4.1.1). Note the scope of the deauth step: PMF is mandatory for WPA3-Personal and cryptographically protects deauthentication/disassociation frames once the association's keys are installed, so a forged deauth does not work against an established WPA3-SAE association — unprotected deauth is still processed before the PTK is installed, but the rogue-AP downgrade itself needs no deauth. The designed mitigation is client-side Transition Disable. This downgrade attack is not a protocol vulnerability — it exploits the transition mode fallback.

Practical implications for WiFi security in 2026

WPA3-only networks (no transition mode) provide genuine protection against password cracking from captured handshakes. The SAE protocol's design eliminates the offline dictionary attack that has been the primary WiFi password recovery method since WPA2 was introduced in 2004.

However, WPA3-only mode requires ALL clients on the network to support WPA3, and many older and low-cost IoT devices (cameras, smart plugs, sensors) still ship with WPA2-only chipsets. That is the practical reason many home networks keep running transition mode, and with it the WPA2 attack surface.

For WiFi password recovery on networks you own or are authorized to administer, the shift to WPA3 reduces the effectiveness of handshake-based recovery. Recovery work is adapting by focusing on: (1) router admin password access (default creds, factory reset, physical access) on equipment you own, (2) saved-password extraction from Windows/macOS/iOS/Android, (3) WPA2 handshake capture from Transition Mode networks you are authorized to test.

SAE handshake security assessment — test only networks you own or have documented written authorization for

  1. 1

    Check if the network supports WPA3

    Use Wireshark to inspect beacon frames you captured on your own network — RSN IE AKM field. AKM 00-0F-AC:8 = WPA3 SAE.

  2. 2

    Check for Transition Mode

    If both AKM 8 (SAE) and AKM 2 (PSK) are advertised, the network falls back to WPA2 — crackable via handshake capture on a network you are authorized to test.

  3. 3

    Understand the downgrade path

    A rogue AP advertising only the WPA2 AKM can capture a downgrade if clients fall back to WPA2. This describes the attack — running it against a network you do not own or have documented written permission to test is unauthorized access and interference.

  4. 4

    For pure WPA3 networks

    Offline cracking from a passive capture is not possible. Recovery of your own network depends on device-extraction (saved passwords) or router admin access.

  5. 5

    Audit group selection

    Ensure the AP rejects groups 1 and 2 (MODP) and any MODP group below 3072 bits; group 19 (P-256) is mandatory to implement. Check the AP's own SAE group policy (web interface, or hostapd/wpa_supplicant debug logs) — hcxdumptool detects SAE authentication but does not enumerate accepted groups, and no hashcat mode exists for SAE.

Frequently Asked Questions

Can WPA3 SAE be cracked offline?
No for a purely passive capture — but an attacker who impersonates the AP can capture the exchange and then test candidates offline at one hash-to-curve per candidate, so SAE raises the cost of recovery rather than removing it.
What is the Password Element (PWE)?
A cryptographic mapping from the password string to a point on an elliptic curve (or finite field element), derived via hash-to-curve over the password, the SSID and both devices' MAC addresses. PWE is the shared secret input SAE's Dragonfly exchange works from; because it is re-randomised per exchange, capturing the exchange does not give an attacker a value to test password guesses against.
Does SAE use the same password as WPA2?
In WPA3 Transition Mode, yes — the same PSK is used for both SAE and WPA2 handshakes. In pure WPA3 mode, only SAE is used.
What is the anti-clogging token?
A cookie mechanism: under load the AP rejects the Commit with status 76 (Anti-Clogging Token Requested) and the client retries with the token; no computation is required of the client.
Can SAE be attacked with quantum computers?
Both ECC-based and FFC-based SAE fall to Shor's algorithm; no practical quantum attack exists in 2026.
Is WPA3 Transition Mode a security flaw?
Not a protocol flaw, but a practical weakness. WPA3-Personal transition mode is an optional backward-compatibility mode (and is not permitted in 6 GHz); WPA3 client devices are required to implement Transition Disable. Anyone serious about WPA3 security should use WPA3-only mode with compatible clients.

Can't find the WiFi password another way?

If every device-side method failed, use the authorized recovery form for a file-specific assessment. The result depends on capture quality, password clues, and the candidate set that can be justified.

Open Recovery Tool

Related Reading