/hostap-latest/src/common/ |
D | dpp_pkex.c | 37 const struct dpp_curve_params *curve = pkex->own_bi->curve; in dpp_pkex_build_exchange_req() local 43 Qi = dpp_pkex_derive_Qi(curve, v2 ? NULL : pkex->own_mac, pkex->code, in dpp_pkex_build_exchange_req() 59 pkex->x = dpp_gen_keypair(curve); in dpp_pkex_build_exchange_req() 62 pkex->x = dpp_gen_keypair(curve); in dpp_pkex_build_exchange_req() 86 attr_len += 4 + 2 * curve->prime_len; in dpp_pkex_build_exchange_req() 111 wpabuf_put_le16(msg, curve->ike_group); in dpp_pkex_build_exchange_req() 133 wpabuf_put_le16(msg, 2 * curve->prime_len); in dpp_pkex_build_exchange_req() 138 if (dpp_test_gen_invalid_key(msg, curve) < 0) in dpp_pkex_build_exchange_req() 144 Mx = wpabuf_put(msg, curve->prime_len); in dpp_pkex_build_exchange_req() 145 My = wpabuf_put(msg, curve->prime_len); in dpp_pkex_build_exchange_req() [all …]
|
D | dpp_crypto.c | 99 static int dpp_hash_vector(const struct dpp_curve_params *curve, in dpp_hash_vector() argument 103 if (curve->hash_len == 32) in dpp_hash_vector() 105 if (curve->hash_len == 48) in dpp_hash_vector() 107 if (curve->hash_len == 64) in dpp_hash_vector() 270 struct crypto_ec_key * dpp_gen_keypair(const struct dpp_curve_params *curve) in dpp_gen_keypair() argument 276 key = crypto_ec_key_gen(curve->ike_group); in dpp_gen_keypair() 284 struct crypto_ec_key * dpp_set_keypair(const struct dpp_curve_params **curve, in dpp_set_keypair() argument 302 *curve = dpp_get_curve_ike_group(group); in dpp_set_keypair() 303 if (!*curve) { in dpp_set_keypair() 333 int dpp_keygen(struct dpp_bootstrap_info *bi, const char *curve, in dpp_keygen() argument [all …]
|
D | dpp_reconfig.c | 138 4 + auth->curve->nonce_len; in dpp_reconfig_build_req() 175 wpabuf_put_le16(msg, auth->curve->nonce_len); in dpp_reconfig_build_req() 176 wpabuf_put_data(msg, auth->c_nonce, auth->curve->nonce_len); in dpp_reconfig_build_req() 188 const struct dpp_curve_params *curve) in dpp_configurator_build_own_connector() argument 198 conf->curve->name); in dpp_configurator_build_own_connector() 199 conf->connector_key = dpp_gen_keypair(curve); in dpp_configurator_build_own_connector() 204 dppcon = wpabuf_alloc(1000 + 2 * curve->prime_len * 4 / 3); in dpp_configurator_build_own_connector() 217 curve) < 0) { in dpp_configurator_build_own_connector() 244 const struct dpp_curve_params *curve; in dpp_reconfig_init() local 248 curve = dpp_get_curve_ike_group(group); in dpp_reconfig_init() [all …]
|
D | dpp_auth.c | 205 if (aes_siv_encrypt(auth->k1, auth->curve->hash_len, clear, siv_len, in dpp_auth_build_req() 391 if (aes_siv_encrypt(siv_key, auth->curve->hash_len, clear, siv_len, in dpp_auth_build_resp() 443 nonce_len = auth->curve->nonce_len; in dpp_auth_build_resp_ok() 451 nonce_len = auth->curve->nonce_len; in dpp_auth_build_resp_ok() 470 auth->own_protocol_key = dpp_gen_keypair(auth->curve); in dpp_auth_build_resp_ok() 473 auth->own_protocol_key = dpp_gen_keypair(auth->curve); in dpp_auth_build_resp_ok() 492 auth->curve->hash_len) < 0) in dpp_auth_build_resp_ok() 506 WPA_PUT_LE16(&r_auth[2], auth->curve->hash_len); in dpp_auth_build_resp_ok() 512 r_auth[4 + auth->curve->hash_len / 2] ^= 0x01; in dpp_auth_build_resp_ok() 515 if (aes_siv_encrypt(auth->ke, auth->curve->hash_len, in dpp_auth_build_resp_ok() [all …]
|
D | dpp.c | 797 nonce_len = auth->curve->nonce_len; in dpp_build_conf_req_attr() 817 clear_len += 4 + auth->curve->hash_len; in dpp_build_conf_req_attr() 871 wpabuf_put_le16(clear, auth->curve->hash_len); in dpp_build_conf_req_attr() 872 wpabuf_put_data(clear, auth_i, auth->curve->hash_len); in dpp_build_conf_req_attr() 891 if (aes_siv_encrypt(auth->ke, auth->curve->hash_len, in dpp_build_conf_req_attr() 1558 const struct dpp_curve_params *curve) in dpp_build_jwk() argument 1571 json_add_string(buf, "crv", curve->jwk_crv); in dpp_build_jwk() 1574 if (json_add_base64url(buf, "x", pos, curve->prime_len) < 0) in dpp_build_jwk() 1577 pos += curve->prime_len; in dpp_build_jwk() 1578 if (json_add_base64url(buf, "y", pos, curve->prime_len) < 0) in dpp_build_jwk() [all …]
|
D | dpp_i.h | 52 const struct dpp_curve_params *curve); 106 int dpp_keygen(struct dpp_bootstrap_info *bi, const char *curve, 108 struct crypto_ec_key * dpp_gen_keypair(const struct dpp_curve_params *curve); 117 int dpp_derive_pmkid(const struct dpp_curve_params *curve, 121 dpp_pkex_derive_Qi(const struct dpp_curve_params *curve, const u8 *mac_init, 125 dpp_pkex_derive_Qr(const struct dpp_curve_params *curve, const u8 *mac_resp, 149 const struct dpp_curve_params *curve);
|
D | dpp.h | 183 const struct dpp_curve_params *curve; member 285 const struct dpp_curve_params *curve; member 411 const struct dpp_curve_params *curve; member 666 const char *curve, int ap); 701 const struct dpp_curve_params *curve; member 711 struct crypto_ec_key * dpp_set_keypair(const struct dpp_curve_params **curve,
|
D | dpp_backup.c | 112 static struct wpabuf * dpp_build_key_alg(const struct dpp_curve_params *curve) in dpp_build_key_alg() argument 117 switch (curve->ike_group) { in dpp_build_key_alg() 159 alg = dpp_build_key_alg(auth->conf->curve); in dpp_build_key_pkg() 279 key_len = auth->curve->hash_len; in dpp_build_pw_recipient_info() 471 hash_len = auth->conf->curve->hash_len; in dpp_build_enveloped_data() 1151 key_len = auth->curve->hash_len; in dpp_conf_resp_env_data()
|
/hostap-latest/wpa_supplicant/examples/ |
D | dpp-qrcode.py | 75 def dpp_display(curve): argument 90 if curve: 91 cmd += " curve=" + curve 127 dpp_display(args.curve)
|
D | dpp-nfc.py | 173 curve=None, key=None): argument 186 if curve: 187 cmd += " curve=" + curve
|
/hostap-latest/tests/hwsim/ |
D | hostapd.py | 472 curve=None, key=None, supported_curves=None, argument 483 if curve: 484 cmd += " curve=" + curve 558 def dpp_pkex_init(self, identifier, code, role=None, key=None, curve=None, argument 561 id1 = self.dpp_bootstrap_gen(type="pkex", key=key, curve=curve) 580 def dpp_pkex_resp(self, freq, identifier, code, key=None, curve=None, argument 582 id0 = self.dpp_bootstrap_gen(type="pkex", key=key, curve=curve) 592 def dpp_configurator_add(self, curve=None, key=None, argument 595 if curve: 596 cmd += " curve=" + curve [all …]
|
D | test_dpp.py | 236 for curve, hex in tests: 240 raise Exception("Failed to get info for " + curve) 241 if "curve=" + curve not in info: 242 raise Exception("Curve mismatch for " + curve) 250 for curve, hex in tests: 254 raise Exception("Failed to get info for " + curve) 255 if "curve=" + curve not in info: 256 raise Exception("Curve mismatch for " + curve) 300 curve = val 303 bi.append((curve, uri)) [all …]
|
D | wpasupplicant.py | 1513 curve=None, key=None, supported_curves=None, argument 1524 if curve: 1525 cmd += " curve=" + curve 1622 def dpp_pkex_init(self, identifier, code, role=None, key=None, curve=None, argument 1626 id1 = self.dpp_bootstrap_gen(type="pkex", key=key, curve=curve) 1651 def dpp_pkex_resp(self, freq, identifier, code, key=None, curve=None, argument 1654 id0 = self.dpp_bootstrap_gen(type="pkex", key=key, curve=curve) 1667 def dpp_configurator_add(self, curve=None, key=None, argument 1670 if curve: 1671 cmd += " curve=" + curve
|
/hostap-latest/src/ap/ |
D | dpp_hostapd.c | 160 if (peer_bi->curve != own_bi->curve) { in hostapd_dpp_nfc_handover_sel() 328 if (peer_bi->curve != own_bi->curve) { in hostapd_dpp_pkex_done() 331 peer_bi->curve->name, own_bi->curve->name); in hostapd_dpp_pkex_done() 897 if (peer_bi->curve != own_bi->curve) { in hostapd_dpp_auth_init() 900 peer_bi->curve->name, own_bi->curve->name); in hostapd_dpp_auth_init() 2441 ifaces->dpp_pb_bi->curve->nonce_len, in hostapd_dpp_pb_pkex_init() 2668 ifaces->dpp_pb_bi->curve->nonce_len)) { in hostapd_dpp_rx_pb_presence_announcement() 2688 ifaces->dpp_pb_bi->curve->nonce_len); in hostapd_dpp_rx_pb_presence_announcement() 2791 const struct dpp_curve_params *curve; in hostapd_dpp_rx_priv_peer_intro_update() local 2838 own_key = dpp_set_keypair(&curve, in hostapd_dpp_rx_priv_peer_intro_update() [all …]
|
D | ieee802_11.c | 4870 buflen += 5 + sta->dpp_pfs->curve->prime_len; in send_assoc_resp()
|
/hostap-latest/wpa_supplicant/ |
D | dpp_supplicant.c | 183 if (peer_bi->curve != own_bi->curve) { in wpas_dpp_nfc_handover_sel() 903 if (peer_bi->curve != own_bi->curve) { in wpas_dpp_auth_init() 906 peer_bi->curve->name, own_bi->curve->name); in wpas_dpp_auth_init() 2987 if (peer_bi->curve != own_bi->curve) { in wpas_dpp_pkex_done() 2990 peer_bi->curve->name, own_bi->curve->name); in wpas_dpp_pkex_done() 3493 wpa_s->dpp_pb_bi->curve->nonce_len, in wpas_dpp_pb_pkex_init() 3630 wpa_s->dpp_pb_bi->curve->nonce_len)) { in wpas_dpp_rx_pb_presence_announcement() 3650 wpa_s->dpp_pb_bi->curve->nonce_len); in wpas_dpp_rx_pb_presence_announcement() 4396 char *curve = NULL; in wpas_dpp_configurator_sign() local 4402 curve = get_param(cmd, " curve="); in wpas_dpp_configurator_sign() [all …]
|