/freebsd/contrib/wpa/src/eap_server/ |
H A D | eap_server_gpsk.c | 2 * hostapd / EAP-GPSK (RFC 5433) server 3 * Copyright (c) 2006-2007, Jouni Malinen <j@w1.fi> 43 return "GPSK-1"; in eap_gpsk_state_txt() 45 return "GPSK-3"; in eap_gpsk_state_txt() 58 wpa_printf(MSG_DEBUG, "EAP-GPSK: %s -> %s", in eap_gpsk_state() 59 eap_gpsk_state_txt(data->state), in eap_gpsk_state() 61 data->state = state; in eap_gpsk_state() 72 data->state = GPSK_1; in eap_gpsk_init() 74 data->csuite_count = 0; in eap_gpsk_init() 77 WPA_PUT_BE32(data->csuite_list[data->csuite_count].vendor, in eap_gpsk_init() [all …]
|
H A D | eap_server_sake.c | 2 * hostapd / EAP-SAKE (RFC 4763) server 3 * Copyright (c) 2006-2007, Jouni Malinen <j@w1.fi> 54 wpa_printf(MSG_DEBUG, "EAP-SAKE: %s -> %s", in eap_sake_state() 55 eap_sake_state_txt(data->state), in eap_sake_state() 57 data->state = state; in eap_sake_state() 68 data->state = CHALLENGE; in eap_sake_init() 70 if (os_get_random(&data->session_id, 1)) { in eap_sake_init() 71 wpa_printf(MSG_ERROR, "EAP-SAKE: Failed to get random data"); in eap_sake_init() 75 wpa_printf(MSG_DEBUG, "EAP-SAKE: Initialized Session ID %d", in eap_sake_init() 76 data->session_id); in eap_sake_init() [all …]
|
/freebsd/contrib/wpa/src/eap_common/ |
H A D | eap_gpsk_common.c | 2 * EAP server/peer: EAP-GPSK shared routines 3 * Copyright (c) 2006-2007, Jouni Malinen <j@w1.fi> 19 * eap_gpsk_supported_ciphersuite - Check whether ciphersuite is supported 49 /* M_i = MAC_Y (i || Z); (MAC = AES-CMAC-128) */ in eap_gpsk_gkdf_cmac() 57 n = (len + hashlen - 1) / hashlen; in eap_gpsk_gkdf_cmac() 61 return -1; in eap_gpsk_gkdf_cmac() 65 left -= clen; in eap_gpsk_gkdf_cmac() 84 /* M_i = MAC_Y (i || Z); (MAC = HMAC-SHA256) */ in eap_gpsk_gkdf_sha256() 92 n = (len + hashlen - 1) / hashlen; in eap_gpsk_gkdf_sha256() 96 return -1; in eap_gpsk_gkdf_sha256() [all …]
|
H A D | eap_sake_common.c | 2 * EAP server/peer: EAP-SAKE shared routines 3 * Copyright (c) 2006-2019, Jouni Malinen <j@w1.fi> 25 wpa_printf(MSG_DEBUG, "EAP-SAKE: Parse: AT_RAND_S"); in eap_sake_parse_add_attr() 27 wpa_printf(MSG_DEBUG, "EAP-SAKE: AT_RAND_S with " in eap_sake_parse_add_attr() 29 return -1; in eap_sake_parse_add_attr() 31 attr->rand_s = data; in eap_sake_parse_add_attr() 34 wpa_printf(MSG_DEBUG, "EAP-SAKE: Parse: AT_RAND_P"); in eap_sake_parse_add_attr() 36 wpa_printf(MSG_DEBUG, "EAP-SAKE: AT_RAND_P with " in eap_sake_parse_add_attr() 38 return -1; in eap_sake_parse_add_attr() 40 attr->rand_p = data; in eap_sake_parse_add_attr() [all …]
|
/freebsd/contrib/wpa/src/common/ |
H A D | wpa_common.c | 2 * WPA/RSN - Shared functions for supplicant and authenticator 3 * Copyright (c) 2002-2018, Jouni Malinen <j@w1.fi> 131 * wpa_use_akm_defined - Is AKM-defined Key Descriptor Version used 133 * Returns: 1 if AKM-defined Key Descriptor Version is used; 0 otherwise 149 * wpa_use_cmac - Is CMAC integrity algorithm used for EAPOL-Key MIC 167 * wpa_use_aes_key_wrap - Is AES Keywrap algorithm used for EAPOL-Key Key Data 171 * Note: AKM 00-0F-AC:1 and 00-0F-AC:2 have special rules for selecting whether 189 * wpa_eapol_key_mic - Calculate EAPOL-Key MIC 190 * @key: EAPOL-Key Key Confirmation Key (KCK) 196 * @mic: Pointer to the buffer to which the EAPOL-Key MIC is written [all …]
|
H A D | wpa_common.h | 3 * Copyright (c) 2002-2018, Jouni Malinen <j@w1.fi> 123 /* EAPOL-Key Key Data Encapsulation 172 /* B2-B3: PTKSA Replay Counter */ 173 /* B4-B5: GTKSA Replay Counter */ 192 /* FTE - MIC Control - RSNXE Used */ 197 /* FTE - MIC Length subfield values */ 205 /* IEEE 802.11, 8.5.2 EAPOL-Key frames */ 236 /* variable length Key MIC field */ 237 /* big endian 2-octet Key Data Length field */ 253 * struct wpa_ptk - WPA Pairwise Transient Key [all …]
|
H A D | ieee802_11_common.c | 3 * Copyright (c) 2002-2019, Jouni Malinen <j@w1.fi> 15 #include "qca-vendor.h" 20 static int ieee802_11_parse_vendor_specific(const u8 *pos, size_t elen, in ieee802_11_parse_vendor_specific() argument 28 * sub-type. */ in ieee802_11_parse_vendor_specific() 35 return -1; in ieee802_11_parse_vendor_specific() 38 oui = WPA_GET_BE24(pos); in ieee802_11_parse_vendor_specific() 41 /* Microsoft/Wi-Fi information elements are further typed and in ieee802_11_parse_vendor_specific() 43 switch (pos[3]) { in ieee802_11_parse_vendor_specific() 47 elems->wpa_ie = pos; in ieee802_11_parse_vendor_specific() 48 elems->wpa_ie_len = elen; in ieee802_11_parse_vendor_specific() [all …]
|
/freebsd/contrib/wpa/src/rsn_supp/ |
H A D | tdls.c | 2 * wpa_supplicant - TDLS 3 * Copyright (c) 2010-2011, Atheros Communications 56 u8 mic[TDLS_MIC_LEN]; member 77 /* TDLS frame headers as per IEEE Std 802.11z-2010 */ 84 static u8 * wpa_add_tdls_timeoutie(u8 *pos, u8 *ie, size_t ie_len, u32 tsecs); 112 u8 kck[16]; /* TPK-KCK */ 113 u8 tk[16]; /* TPK-TK; assuming only CCMP will be used */ 116 int tk_set; /* TPK-TK configured to the driver */ 172 return sm->mlo.links[link_id].bssid; in wpa_tdls_get_link_bssid() 173 return sm->bssid; in wpa_tdls_get_link_bssid() [all …]
|
H A D | wpa_ft.c | 2 * WPA Supplicant - IEEE 802.11r - Fast BSS Transition 3 * Copyright (c) 2006-2018, Jouni Malinen <j@w1.fi> 41 const u8 *anonce = key->key_nonce; in wpa_derive_ptk_ft() 42 int use_sha384 = wpa_key_mgmt_sha384(sm->key_mgmt); in wpa_derive_ptk_ft() 47 if (sm->xxkey_len > 0) { in wpa_derive_ptk_ft() 48 mpmk = sm->xxkey; in wpa_derive_ptk_ft() 49 mpmk_len = sm->xxkey_len; in wpa_derive_ptk_ft() 50 } else if (sm->cur_pmksa) { in wpa_derive_ptk_ft() 51 mpmk = sm->cur_pmksa->pmk; in wpa_derive_ptk_ft() 52 mpmk_len = sm->cur_pmksa->pmk_len; in wpa_derive_ptk_ft() [all …]
|
H A D | wpa.c | 2 * WPA Supplicant - WPA state machine and EAPOL-Key processing 3 * Copyright (c) 2003-2018, Jouni Malinen <j@w1.fi> 80 * wpa_eapol_key_send - Send WPA/RSN EAPOL-Key message 86 * @msg: EAPOL-Key message 88 * @key_mic: Pointer to the buffer to which the EAPOL-Key MIC is written 95 int ret = -1; in wpa_eapol_key_send() 96 size_t mic_len = wpa_mic_len(sm->key_mgmt, sm->pmk_len); in wpa_eapol_key_send() 98 wpa_printf(MSG_DEBUG, "WPA: Send EAPOL-Key frame to " MACSTR in wpa_eapol_key_send() 100 MAC2STR(dest), ver, (int) mic_len, sm->key_mgmt); in wpa_eapol_key_send() 101 if (is_zero_ether_addr(dest) && is_zero_ether_addr(sm->bssid)) { in wpa_eapol_key_send() [all …]
|
/freebsd/contrib/wpa/src/eap_peer/ |
H A D | eap_gpsk.c | 2 * EAP peer method: EAP-GPSK (RFC 5433) 3 * Copyright (c) 2006-2014, Jouni Malinen <j@w1.fi> 53 return "GPSK-1"; in eap_gpsk_state_txt() 55 return "GPSK-3"; in eap_gpsk_state_txt() 69 wpa_printf(MSG_DEBUG, "EAP-GPSK: %s -> %s", in eap_gpsk_state() 70 eap_gpsk_state_txt(data->state), in eap_gpsk_state() 72 data->state = state; in eap_gpsk_state() 88 wpa_printf(MSG_INFO, "EAP-GPSK: No key (password) configured"); in eap_gpsk_init() 95 data->state = GPSK_1; in eap_gpsk_init() 99 data->id_peer = os_memdup(identity, identity_len); in eap_gpsk_init() [all …]
|
H A D | eap_sake.c | 2 * EAP peer method: EAP-SAKE (RFC 4763) 3 * Copyright (c) 2006-2019, Jouni Malinen <j@w1.fi> 58 wpa_printf(MSG_DEBUG, "EAP-SAKE: %s -> %s", in eap_sake_state() 59 eap_sake_state_txt(data->state), in eap_sake_state() 61 data->state = state; in eap_sake_state() 76 wpa_printf(MSG_INFO, "EAP-SAKE: No key of correct length " in eap_sake_init() 84 data->state = IDENTITY; in eap_sake_init() 88 data->peerid = os_memdup(identity, identity_len); in eap_sake_init() 89 if (data->peerid == NULL) { in eap_sake_init() 93 data->peerid_len = identity_len; in eap_sake_init() [all …]
|
/freebsd/contrib/wpa/wpa_supplicant/ |
H A D | mesh_rsn.c | 2 * WPA Supplicant - Mesh RSN routines 3 * Copyright (c) 2013-2014, cozybit, Inc. All rights reserved. 37 if (sta->sae->state != SAE_ACCEPTED) { in mesh_auth_timer() 38 wpa_printf(MSG_DEBUG, "AUTH: Re-authenticate with " MACSTR in mesh_auth_timer() 40 MAC2STR(sta->addr), sta->sae_auth_retry); in mesh_auth_timer() 42 MAC2STR(sta->addr)); in mesh_auth_timer() 43 if (sta->sae_auth_retry < MESH_AUTH_RETRY) { in mesh_auth_timer() 46 hapd = wpa_s->ifmsh->bss[0]; in mesh_auth_timer() 48 if (sta->sae_auth_retry > MESH_AUTH_RETRY) { in mesh_auth_timer() 55 sta->sae->state = SAE_NOTHING; in mesh_auth_timer() [all …]
|
H A D | mesh_mpm.c | 2 * WPA Supplicant - Basic mesh peer management 3 * Copyright (c) 2013-2014, cozybit, Inc. All rights reserved. 79 mpm_ie->chosen_pmk = ie + len - SAE_PMKID_LEN; in mesh_mpm_parse_peer_mgmt() 80 len -= SAE_PMKID_LEN; in mesh_mpm_parse_peer_mgmt() 87 return -1; in mesh_mpm_parse_peer_mgmt() 92 return -1; in mesh_mpm_parse_peer_mgmt() 93 mpm_ie->proto_id = ie; in mesh_mpm_parse_peer_mgmt() 94 mpm_ie->llid = ie + 2; in mesh_mpm_parse_peer_mgmt() 96 len -= 4; in mesh_mpm_parse_peer_mgmt() 101 return -1; in mesh_mpm_parse_peer_mgmt() [all …]
|
H A D | events.c | 2 * WPA Supplicant - Driver event processing 3 * Copyright (c) 2003-2019, Jouni Malinen <j@w1.fi> 72 if (ssid == NULL || ssid->disabled_until.sec == 0) in wpas_temp_disabled() 76 if (ssid->disabled_until.sec > now.sec) in wpas_temp_disabled() 77 return ssid->disabled_until.sec - now.sec; in wpas_temp_disabled() 87 * wpas_reenabled_network_time - Time until first network is re-enabled 90 * (in sec) until the first network is re-enabled. Otherwise returns 0. 94 * re-enabled. The function assumes that at least one network is enabled. 102 if (wpa_s->conf->auto_interworking && wpa_s->conf->interworking && in wpas_reenabled_network_time() 103 wpa_s->conf->cred) in wpas_reenabled_network_time() [all …]
|
/freebsd/sys/net80211/ |
H A D | ieee80211_crypto_ccmp.c | 1 /*- 2 * SPDX-License-Identifier: BSD-2-Clause 4 * Copyright (c) 2002-2008 Sam Leffler, Errno Consulting 30 * IEEE 802.11i AES-CCMP crypto support. 73 .ic_name = "AES-CCM", 104 vap->iv_stats.is_crypto_nomem++; in ccmp_attach() 107 ctx->cc_vap = vap; in ccmp_attach() 108 ctx->cc_ic = vap->iv_ic; in ccmp_attach() 116 struct ccmp_ctx *ctx = k->wk_private; in ccmp_detach() 120 nrefs--; /* NB: we assume caller locking */ in ccmp_detach() [all …]
|
H A D | ieee80211_crypto_tkip.c | 1 /*- 2 * SPDX-License-Identifier: BSD-2-Clause 4 * Copyright (c) 2002-2008 Sam Leffler, Errno Consulting 94 uint64_t rx_rsc; /* held until MIC verified */ 99 u8 mic[IEEE80211_WEP_MICLEN]); 116 vap->iv_stats.is_crypto_nomem++; in tkip_attach() 120 ctx->tc_vap = vap; in tkip_attach() 128 struct tkip_ctx *ctx = k->wk_private; in tkip_detach() 132 nrefs--; /* NB: we assume caller locking */ in tkip_detach() 138 struct tkip_ctx *ctx = k->wk_private; in tkip_setkey() [all …]
|
H A D | ieee80211_crypto_wep.c | 1 /*- 2 * SPDX-License-Identifier: BSD-2-Clause 4 * Copyright (c) 2002-2008 Sam Leffler, Errno Consulting 95 vap->iv_stats.is_crypto_nomem++; in wep_attach() 99 ctx->wc_vap = vap; in wep_attach() 100 ctx->wc_ic = vap->iv_ic; in wep_attach() 101 net80211_get_random_bytes(&ctx->wc_iv, sizeof(ctx->wc_iv)); in wep_attach() 109 struct wep_ctx *ctx = k->wk_private; in wep_detach() 113 nrefs--; /* NB: we assume caller locking */ in wep_detach() 119 return k->wk_keylen >= 40/NBBY; in wep_setkey() [all …]
|
/freebsd/sys/contrib/device-tree/Bindings/sound/ |
H A D | microchip,pdmc.yaml | 1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 3 --- 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Codrin Ciubotariu <codrin.ciubotariu@microchip.com> 17 - $ref: dai-common.yaml# 21 const: microchip,sama7g5-pdmc 26 "#sound-dai-cells": 34 - description: Peripheral Bus Clock 35 - description: Generic Clock 37 clock-names: [all …]
|
H A D | microchip,sama7g5-pdmc.yaml | 1 # SPDX-License-Identifier: (GPL-2.0 OR BSD-2-Clause) 3 --- 4 $id: http://devicetree.org/schemas/sound/microchip,sama7g5-pdmc.yaml# 5 $schema: http://devicetree.org/meta-schemas/core.yaml# 10 - Codrin Ciubotariu <codrin.ciubotariu@microchip.com> 17 - $ref: dai-common.yaml# 21 const: microchip,sama7g5-pdmc 26 "#sound-dai-cells": 34 - description: Peripheral Bus Clock 35 - description: Generic Clock [all …]
|
/freebsd/contrib/wpa/src/ap/ |
H A D | wpa_auth.c | 3 * Copyright (c) 2004-2022, Jouni Malinen <j@w1.fi> 73 static u8 * ieee80211w_kde_add(struct wpa_state_machine *sm, u8 *pos); 92 if (sm->mld_assoc_link_id >= 0) in wpa_auth_get_aa() 93 return sm->wpa_auth->mld_addr; in wpa_auth_get_aa() 95 return sm->wpa_auth->addr; in wpa_auth_get_aa() 102 if (sm->mld_assoc_link_id >= 0) in wpa_auth_get_spa() 103 return sm->peer_mld_addr; in wpa_auth_get_spa() 105 return sm->addr; in wpa_auth_get_spa() 115 if (!sm->wpa_auth) in wpa_gkeydone_sta() 118 sm->wpa_auth->group->GKeyDoneStations--; in wpa_gkeydone_sta() [all …]
|
H A D | wpa_auth_ft.c | 2 * hostapd - IEEE 802.11r - Fast BSS Transition 3 * Copyright (c) 2004-2018, Jouni Malinen <j@w1.fi> 58 * wpa_ft_rrb_decrypt - Decrypt FT RRB message 59 * @key: AES-SIV key for AEAD 66 * @type: Vendor-specific subtype of the RRB frame (FT_PACKET_*) 72 * Returns: 0 on success, -1 on error 105 *plain = os_zalloc(enc_len - AES_BLOCK_SIZE); in wpa_ft_rrb_decrypt() 117 enc_len -= 2; in wpa_ft_rrb_decrypt() 123 *plain_size = enc_len - AES_BLOCK_SIZE; in wpa_ft_rrb_decrypt() 134 return -1; in wpa_ft_rrb_decrypt() [all …]
|
/freebsd/contrib/wpa/src/drivers/ |
H A D | driver_bsd.c | 2 * WPA Supplicant - driver interaction with BSD net80211 layer 85 dl_list_for_each(drv, &global->ifaces, struct bsd_driver_data, list) { in bsd_get_drvindex() 86 if (drv->ifindex == ifindex) in bsd_get_drvindex() 98 dl_list_for_each(drv, &global->ifaces, struct bsd_driver_data, list) { in bsd_get_drvname() 99 if (os_strcmp(drv->ifname, ifname) == 0) in bsd_get_drvname() 111 if (drv->ifindex == 0 || drv->if_removed) in bsd_set80211() 112 return -1; in bsd_set80211() 115 os_strlcpy(ireq.i_name, drv->ifname, sizeof(ireq.i_name)); in bsd_set80211() 121 if (ioctl(drv->global->sock, SIOCS80211, &ireq) < 0) { in bsd_set80211() 125 return -1; in bsd_set80211() [all …]
|
H A D | driver_wext.c | 3 * Copyright (c) 2003-2015, Jouni Malinen <j@w1.fi> 9 * When used with WE-18 or newer, this interface can be used as-is with number 49 os_strlcpy(iwr.ifr_name, drv->ifname, IFNAMSIZ); in wpa_driver_wext_set_auth_param() 53 if (ioctl(drv->ioctl_sock, SIOCSIWAUTH, &iwr) < 0) { in wpa_driver_wext_set_auth_param() 59 ret = errno == EOPNOTSUPP ? -2 : -1; in wpa_driver_wext_set_auth_param() 67 * wpa_driver_wext_get_bssid - Get BSSID, SIOCGIWAP 70 * Returns: 0 on success, -1 on failure 79 os_strlcpy(iwr.ifr_name, drv->ifname, IFNAMSIZ); in wpa_driver_wext_get_bssid() 81 if (ioctl(drv->ioctl_sock, SIOCGIWAP, &iwr) < 0) { in wpa_driver_wext_get_bssid() 83 ret = -1; in wpa_driver_wext_get_bssid() [all …]
|
/freebsd/sys/contrib/device-tree/src/arm/microchip/ |
H A D | at91-sama7g5ek.dts | 1 // SPDX-License-Identifier: (GPL-2.0+ OR MIT) 3 * at91-sama7g5ek.dts - Device Tree file for SAMA7G5-EK board 11 /dts-v1/; 12 #include "sama7g5-pinfunc.h" 14 #include <dt-bindings/mfd/atmel-flexcom.h> 15 #include <dt-bindings/input/input.h> 16 #include <dt-bindings/pinctrl/at91.h> 17 #include <dt-bindings/sound/microchip,pdmc.h> 20 model = "Microchip SAMA7G5-EK"; 25 stdout-path = "serial0:115200n8"; [all …]
|