wpa_supplicant / hostapd
2.5
|
SHA1-based key derivation function (PBKDF2) for IEEE 802.11i. More...
Functions | |
int | pbkdf2_sha1 (const char *passphrase, const u8 *ssid, size_t ssid_len, int iterations, u8 *buf, size_t buflen) |
SHA1-based key derivation function (PBKDF2) for IEEE 802.11i. More... | |
SHA1-based key derivation function (PBKDF2) for IEEE 802.11i.
int pbkdf2_sha1 | ( | const char * | passphrase, |
const u8 * | ssid, | ||
size_t | ssid_len, | ||
int | iterations, | ||
u8 * | buf, | ||
size_t | buflen | ||
) |
SHA1-based key derivation function (PBKDF2) for IEEE 802.11i.
passphrase | ASCII passphrase |
ssid | SSID |
ssid_len | SSID length in bytes |
iterations | Number of iterations to run |
buf | Buffer for the generated key |
buflen | Length of the buffer in bytes |
This function is used to derive PSK for WPA-PSK. For this protocol, iterations is set to 4096 and buflen to 32. This function is described in IEEE Std 802.11-2004, Clause H.4. The main construction is from PKCS#5 v2.0.