Lines Matching refs:pw
151 bool sae_pk_valid_password(const char *pw) in sae_pk_valid_password() argument
154 size_t i, pw_len = os_strlen(pw); in sae_pk_valid_password()
170 for (pos = 0; pw[pos]; pos++) { in sae_pk_valid_password()
172 if (pw[pos] != '-') { in sae_pk_valid_password()
179 if (dtable[(u8) pw[pos]] == 0x80) { in sae_pk_valid_password()
187 if (pw[pw_len - 1] != d_check_char(pw, pw_len - 1)) { in sae_pk_valid_password()
194 sec_1b = dtable[(u8) pw[0]] & BIT(4); in sae_pk_valid_password()
196 if (sec_1b != (dtable[(u8) pw[i]] & BIT(4))) { in sae_pk_valid_password()
385 u8 *pw, *pos; in sae_pk_set_password() local
402 pw = sae_pk_base32_decode(password, len, &pw_len); in sae_pk_set_password()
403 if (!pw) { in sae_pk_set_password()
407 tmp->sec = (pw[0] & BIT(7)) ? 3 : 5; in sae_pk_set_password()
417 wpa_hexdump_key(MSG_DEBUG, "SAE-PK: PasswordBase", pw, pw_len); in sae_pk_set_password()
420 sae_pk_buf_shift_left_1(pw, pw_len); /* Sec_1b */ in sae_pk_set_password()
421 val19 = sae_pk_get_be19(pw); in sae_pk_set_password()
422 sae_pk_buf_shift_left_19(pw, pw_len); in sae_pk_set_password()
442 bin_clear_free(pw, pw_len); in sae_pk_set_password()