WPA-PSK: adding the 8 missing types to hashcat
Related: #3887 (FT-PSK support request), #4645 (FT-PSK SHA-256 PR, covers FT-PSK SHA-256 only)
Problem
Mode 22000 cracks WPA1 (AKM vendor IE) and WPA2-PSK (AKM 2) handshakes and PMKIDs. Eight additional PSK-crackable AKM suites defined in IEEE 802.11-2024 are not supported:
| AKM | Suite | What fails |
|---|---|---|
| 6 | PSK-SHA256 (PMKID) | 22000 runs HMAC-SHA1 unconditionally; an AKM-6 PMKID silently misroutes and never cracks |
| 6 | PSK-SHA256 (EAPOL) | KDF-SHA256 PTK + AES-128-CMAC MIC; 22000 has no KDF-SHA256 path |
| 4 | FT-PSK SHA-256 (PMKID) | FT key hierarchy (PMK-R0, PMK-R1) not implemented; needs MDID, R0KH-ID, R1KH-ID fields |
| 4 | FT-PSK SHA-256 (EAPOL) | Same FT hierarchy + AES-128-CMAC MIC |
| 20 | PSK-SHA384 (PMKID) | No SHA-384 PMKID path in 22000 |
| 20 | PSK-SHA384 (EAPOL) | KDF-SHA384 PTK with 24-byte KCK + 24-byte MIC; 22000's 16-byte MIC field cannot hold it |
| 19 | FT-PSK SHA-384 (PMKID) | FT hierarchy with SHA-384; same missing FT infrastructure |
| 19 | FT-PSK SHA-384 (EAPOL) | FT hierarchy + SHA-384 MIC (24 bytes) |
These are deployed in WPA3-Transition networks (AKM 6 PSK-SHA256), enterprise 802.11r roaming (AKM 4 FT-PSK), and newer APs that advertise AKM 19/20 (PSK-SHA384).
The PBKDF2-HMAC-SHA1 key derivation is identical across all of these; only the post-PMK verification differs per AKM. Together with the three types 22000 already handles (WPA1-PSK-EAPOL, WPA2-PSK-PMKID, WPA2-PSK-EAPOL), these eight make eleven distinct PSK algorithm combos. A single mode covering all eleven would crack mixed-AKM captures in one pass.
Limitations of 22000's current format
- The MIC field is fixed at 32 hex (16 bytes). SHA-384 EAPOL types produce a 24-byte MIC (48 hex) that does not fit.
- Mode 22000 on master has two type codes: 01 = PMKID, 02 = EAPOL. PR #4645 adds 03 and 04 for FT-PSK SHA-256 but is still a draft. The
keyverbyte inside the EAPOL frame cannot distinguish SHA-384 (KDV 0) from future additions. - FT types need three extra fields (MDID, R0KH-ID, R1KH-ID) that 22000's tokenizer does not expect.
- These are parser and format limitations. The kernel side has room: all five aux kernel slots are available (see discussion point 2).
Proposed solution
A new hash format with a self-contained 2-digit decimal type code that encodes everything the cracker needs. Full specification: HASHCAT-NEW-FORMATS.md.
Non-FT types (1, 2, 3, 4, 5, 8, 9):
WPA*TT*<hash>*<ap>*<sta>*<essid>*<nonce>*<eapol>*<mp>FT types (6, 7, 10, 11):
WPA*TT*<hash>*<ap>*<sta>*<essid>*<nonce>*<eapol>*<mp>*<mdid>*<r0kh-id>*<r1kh-id>The type code determines the <hash> field width (32 hex for types 1-8 and 10, 48 hex for SHA-384 EAPOL types 9 and 11), the KDF, the MIC algorithm, and whether FT extras are present. PMKID rows (even codes) leave <nonce> and <eapol> empty.
The eleven types
Under the proposed new-mode numbering (01-11), and what each requires:
| Type | Name | AKM | KDV | KDF | PMKID hash | MIC algo | MIC len | FT chain | Extra fields | Hash hex | 22000 status |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 01 | WPA1-PSK-EAPOL | VI | 1 | PRF-SHA1 | -- | HMAC-MD5 | 16 B | -- | -- | 32 | works |
| 02 | WPA2-PSK-PMKID | 2 | -- | -- | HMAC-SHA1 | -- | -- | -- | -- | 32 | works |
| 03 | WPA2-PSK-EAPOL | 2 | 2 | PRF-SHA1 | -- | HMAC-SHA1 | 16 B | -- | -- | 32 | works |
| 04 | PSK-SHA256-PMKID | 6 | -- | -- | HMAC-SHA256 | -- | -- | -- | -- | 32 | no SHA-256 PMKID path, silent mismatch |
| 05 | PSK-SHA256-EAPOL | 6 | 3 | KDF-SHA256 | -- | AES-128-CMAC | 16 B | -- | -- | 32 | no KDF-SHA256 path, no AES-CMAC path |
| 06 | FT-PSK-PMKID | 4 | -- | FT-KDF-SHA256 | SHA-256 (PMKR1Name) | -- | -- | SHA-256 | MDID, R0KH, R1KH | 32 | no FT chain, format: no FT fields |
| 07 | FT-PSK-EAPOL | 4 | 3 | KDF-SHA256 | -- | AES-128-CMAC | 16 B | SHA-256 | MDID, R0KH, R1KH | 32 | no FT chain, no AES-CMAC, format: no FT fields |
| 08 | PSK-SHA384-PMKID | 20 | -- | -- | HMAC-SHA384 | -- | -- | -- | -- | 32 | no SHA-384 PMKID path |
| 09 | PSK-SHA384-EAPOL | 20 | 0 | KDF-SHA384 | -- | HMAC-SHA384 | 24 B | -- | -- | 48 | no SHA-384 path, format: 32-hex field too narrow |
| 10 | FT-PSK-SHA384-PMKID | 19 | -- | FT-KDF-SHA384 | SHA-384 (PMKR1Name) | -- | -- | SHA-384 | MDID, R0KH, R1KH | 32 | no FT chain, no SHA-384, format: no FT fields |
| 11 | FT-PSK-SHA384-EAPOL | 19 | 0 | KDF-SHA384 | -- | HMAC-SHA384 | 24 B | SHA-384 | MDID, R0KH, R1KH | 48 | no FT chain, no SHA-384, format: too narrow + no FT fields |
[!IMPORTANT] All eleven types share PBKDF2-HMAC-SHA1 (4096 iterations) for key derivation. The type code determines everything after the PMK.
AKM "VI" is the WPA1 vendor-specific IE (OUI 00:50:F2, selector 2). It predates the IEEE 802.11i AKM numbering (00:0F:AC:XX) used by WPA2 and later.
WPAWolf already emits hash lines in this format from pcap/pcapng captures, handling all eleven types, the six N#E# message-pair combos, and the FT extra fields.
Kernel architecture
The kernel architecture was chosen from a bake-off of 10 designs on the feat/wpa-psk-v2 branch (modes 90001-90010), each cracking 155 distinct hashes across all 11 types at 100%. The candidates included monolithic comp, 4-aux by type family, 2-aux by attack surface (PMKID vs EAPOL), per-type aux (one kernel per type, needed a core patch for aux5-11), and GPU+CPU hook hybrids. The winner was the 5-aux surface split (PMKID types in one aux, EAPOL types grouped by cryptographic primitive), which avoids core patches, keeps AES T-tables out of the PMKID/SHA-only aux kernels, and benchmarked fastest on mixed workloads. The bake-off data and rationale are in that branch's WPA-PSK-UNIVERSAL.md and bakeoff-780m.tsv.
Implementation
Both modes are implemented, build clean, and pass test_edge.sh:
feat/wpa-22002: passphrase via PBKDF2 (mirrors mode 22000)feat/wpa-22003: PMK-direct, skips PBKDF2 (mirrors mode 22001)
Discussion points
[!IMPORTANT] Looking for input on the following.
Discussion point 1: new mode or extend 22000?
A new mode (22002) with its own type-code space avoids touching 22000's format. Existing .22000 files, potfiles, scripts, and tooling continue to work with no changes. Extending 22000 is also possible (see points 2 and 3).
The kernel side is not the blocker either way. All five aux kernel slots are available and the 5-aux surface split fits without a core patch. The question is whether the format changes should go into 22000 or a new mode number.
Discussion point 2: if extending 22000, keep types 01-02 and add 03-10?
Since 22000's types 01-02 are the only ones on master (PR #4645's 03-04 are still a draft), 03+ is available for new assignments:
01 PMKID (WPA2-PSK-PMKID, HMAC-SHA1) unchanged, backward compatible
02 EAPOL (WPA1/WPA2-PSK-EAPOL, keyver-driven) unchanged, backward compatible
03 PSK-SHA256-PMKID new
04 PSK-SHA256-EAPOL new
05 FT-PSK-PMKID (SHA-256 FT chain) new, 3 extra fields
06 FT-PSK-EAPOL (SHA-256 FT chain) new, 3 extra fields
07 PSK-SHA384-PMKID new
08 PSK-SHA384-EAPOL (24 B MIC) new, 48-hex hash field
09 FT-PSK-SHA384-PMKID (SHA-384 FT chain) new, 3 extra fields
10 FT-PSK-SHA384-EAPOL (SHA-384 FT chain, 24 B) new, 48-hex hash + 3 extra fieldsExisting WPA*01* and WPA*02* lines parse exactly as before. Types 03-10 require three parser changes: variable hash field width (32 or 48 hex based on the type code), variable field count (9 or 12 for FT types), and new aux kernel verification paths. The parser already reads the type code before the tokenizer runs, so the variable-width logic is the same as in the 22002 implementation.
[!NOTE] This extends 22000 with 8 new type codes and supersedes PR #4645's type code assignments, moving FT-PSK SHA-256 from 03-04 to 05-06. Every tool that reads
WPA*lines would need to handle the new types or reject them gracefully, but existingWPA*01*/WPA*02*lines are untouched.
Discussion point 3: if extending 22000, collapse to just 4 type codes?
01 PMKID (non-FT) try SHA1, SHA256, SHA384 in the kernel
02 EAPOL (non-FT) keyver + MIC length selects the algorithm
03 FT-PMKID try SHA256, SHA384 in the kernel, 3 extra fields
04 FT-EAPOL keyver + MIC length selects, 3 extra fieldsThis avoids new type codes beyond 04 by inferring the algorithm from fields already in the hash line. For PMKIDs, the kernel tries all applicable HMAC hashes and accepts whichever matches (3 HMAC operations, cheap compared to PBKDF2). For EAPOL, keyver 1 = HMAC-MD5, keyver 2 = HMAC-SHA1, keyver 3 = AES-128-CMAC, and keyver 0 with a 24-byte MIC (48-hex hash field) = HMAC-SHA384.
[!WARNING] Problems with this approach:
- The hash field width still varies (32 hex for 16-byte MICs, 48 hex for SHA-384). The parser must accept both under the same type code, which means the format is no longer self-describing from the type code alone.
- Keyver 0 in the spec means "algorithm defined by the negotiated AKM" (IEEE 802.11-2024 Table 12-6), not specifically "SHA-384." A future AKM that uses keyver 0 with a 16-byte MIC would collide and the parser could not distinguish it.
- The PMKID try-all approach wastes GPU cycles on hash types that the emitter already classified. WPAWolf and hcxpcapngtool know the AKM at extraction time and could write the specific type code.
- Types 01-02 would change behavior: existing
WPA*01*lines currently mean "HMAC-SHA1 PMKID" but would now mean "try three PMKID hashes." This is functionally compatible but semantically different.
Both points 2 and 3 need the same kernel changes (5 aux kernels, FT chain, SHA-384 paths, AES-CMAC). The difference is whether the type code explicitly identifies the algorithm (point 2, 10 types) or the kernel infers it from keyver and MIC length (point 3, 4 types).
Discussion point 4: are the algorithm combos the right set?
The eleven algorithm combos cover every PSK-crackable AKM suite in IEEE 802.11-2024 Table 9-190 that derives via PBKDF2-HMAC-SHA1. Are there other PBKDF2-based PSK types I missed? I believe these are exhaustive for the current spec. SAE (AKM 8/9), OWE (AKM 18), and EAP-based suites use different key exchanges and are out of scope.
Discussion point 5: can we retire modes 2500, 2501, 16800, 16801?
These are the legacy modes that 22000/22001 already replaced:
2500 WPA-EAPOL-PBKDF2 (superseded by 22000)
2501 WPA-EAPOL-PMK (superseded by 22001)
16800 WPA-PMKID-PBKDF2 (superseded by 22000)
16801 WPA-PMKID-PMK (superseded by 22001)They still ship in the tree. Can they be removed entirely, or at least marked deprecated with a notice pointing to 22000?
Discussion point 6: SHA-384 types (AKM 19/20), has anyone seen these in the wild?
I have not yet found an AP or network that advertises AKM 19 (FT-PSK-SHA384) or AKM 20 (PSK-SHA384). The spec defines them and the kernel implements them against spec test vectors, but real-world validation is pending. If anyone has access to hardware that supports these (Aruba IAP, Cisco IOS-XE, or similar enterprise APs), a test capture would be valuable.
CC people involved in WPA hash cracking across the ecosystem:
@jsteube @ZerBea @c0rs @RealEnder @MRX-72 @Chick3nman @Rozin14 @dwdrone @PenguinKeeper7 @xoverride @schrotbrot @philsmd @magnumripper @kimocoder @TheLiimbo @neheb @derv82 @jayofelony @v1s1t0r1sh3r3 @andrewjlamarche
Source: hashcat/hashcat