r/Hacking_Tutorials • • Oct 28 '26 • Bravo 1 Heartwarming 1

Question WPA3 was supposed to kill offline dictionary attacks. A timing leak in one ECC step might not let it.

Post image

So I've been working on this for my engineering thesis and wanted to throw the core idea out there before I sink more months into it, in case anyone's spotted something I'm missing.

WPA3 didn't actually replace the WPA2 four-way handshake, it bolted a new layer in front of it called SAE (Simultaneous Authentication of Equals). The whole point of SAE is that you can't precompute anything offline from a captured handshake anymore, because the key material is blinded through a DiffieHellman-ish exchange instead of a static PBKDF2(password, SSID). In theory that kills offline dictionary attacks dead ie every guess needs a live, rate-limited roundtrip with the AP.

The thing I'm chasing is one specific step buried inside SAE: turning your password into a point on the P-256 curve. The "classic" way to do this (hunting-and-pecking) is a loop, hash the password + MAC addresses, check if you land on a valid curve point, if not increment a counter and try again. That counter, k, is small (geometric distribution, mean of like 2), but it's password-dependent, and it leaks through timing. This isn't new, Vanhoef and Ronen showed this back in 2020 (Dragonblood), and it's why H2E (Hash-to-Element) exists as a constant-time replacement.

What I'm doing differently is trying to actually operationalize the leak with cheap hardware and see how far it goes

Built a timing rig out of ESP32s, timestamping the outgoing SAE Commit frame and the AP's response off the same hardware TSF clock (not a software clock, so no OS scheduling jitter messing things up).

Had to patch the ESP-IDF WiFi driver to even send raw Authentication/Commit frames, turns out the stock driver whitelists frame types and silently drops anything else. Fixed it by weakening one ELF symbol's binding so my own override gets linked in instead of the driver's internal check. One-line, fully reversible.

Instead of just doing classic timing analysis, I'm training a profiled/deep-learning model to recover k from the timing traces, the same way you'd do differential power analysis on an AES key byte treating k as the "leaking intermediate" and SAE's two derivation modes (legacy hunting-and-pecking vs H2E) as my "right key / wrong key" arms.

End goal isn't just "yes it leaks" I want to actually drive a real offline dictionary attack off the recovered k and report how close that gets you back to WPA2-level crackability, under each derivation mode.

First real-hardware run already surfaced something useful (and slightly humbling): at 120 samples/arm on a single receiver, I couldn't separate the two arms statistically yet. Turns out normal 802.11 retransmission noise is in the low-millisecond range, while the actual signal I'm chasing is tens of microseconds. So the noise floor is real and bigger than I'd like — which is exactly why the full version of this is a distributed array of sensors instead of one node, plus way more samples.

Curious if anyone here has played with SAE/Dragonfly timing attacks post-Dragonblood, or has opinions on whether H2E actually closes this cleanly in practice vs just raising the bar. Also happy to go into the ESP32/driver-patching side if that's more people's thing.

On a more practical note I'm a final-year student and this is shaping up to be the basis of a master's/PhD, and I don't currently have a supervisor whose background actually overlaps with side-channel analysis or ECC. If anyone here is an academic/researcher in crypto or hardware security (or knows one who might be interested in this kind of work), I'd genuinely love to hear from you.

152 Upvotes

7 comments sorted by

5

u/AllergicToBullshit24 Oct 28 '26

This prior art suggests that no timing data is leaked when using NIST elliptic curves but there could be leaks for Brainpool or MODP: https://wpa3.mathyvanhoef.com/

"When the AP uses security groups based on NIST elliptic curves, which all WPA3 devices are required to support, no timing information is leaked. However, when the AP supports either Brainpool curves, or multiplicative security groups modulo a prime (MODP groups), the response time depends on the password being used. An adversary can abuse this information to perform a dictionary attack, by simulating how much time it would take for the AP to process each password, and comparing this to observed timings."

1

u/gibson_tandi 29d ago

Wow 😮👍🏻👍🏻👍🏻🫡

1

u/wired_zak 28d ago

The ELF symbol override to bypass the whitelist is brilliant. Are you worried that patching out that specific check might introduce micro-stutters in the driver's normal flow, or does the raw TSF clock completely abstract away the OS/driver overhead?

1

u/OrvalZ 24d ago

That's a very interesting project ! All the best 👌🏻

1

u/[deleted] Oct 29 '26

[removed] — view removed comment

1

u/mahdi_sto 29d ago

Not quite true, i discovered that the retransmission noise is happening because the ap is waiting for the sta to send ack frame confirming successful reception of commit response, and given that the frame ks forged at software level then the ap after sending response it waits on the forged mac address to send an ack but given that the hardware level mac address is different from the software forged mac address then the ap woul ignore the ack causing retransmission of the commit response so basically ensuring that the software mac address is written at registers level would prevent retransmission loop reducing the jitter noise.