input
stringlengths
16
454k
output
stringlengths
13
350k
function_name
stringlengths
1
100
repo_name
stringlengths
6
43
category
stringclasses
76 values
sample_id
stringlengths
22
88
decompiler
stringclasses
1 value
opt_level
stringclasses
1 value
wpabuf *wps_build_wsc_nack(wps_data *wps) { wpabuf *msg; wpa_printf(2, "WPS: Building Message WSC_NACK"); msg = wpabuf_alloc(0x3E8u); if (!msg) return 0; if (!wps_build_version(msg) && !wps_build_msg_type(msg, wps_msg_type_WPS_WSC_NACK) && !wps_build_enrollee_nonce(wps, msg) && !wps_bui...
struct wpabuf *wps_build_wsc_nack(struct wps_data *wps) { struct wpabuf *msg; wpa_printf(MSG_DEBUG, "WPS: Building Message WSC_NACK"); msg = wpabuf_alloc(1000); if (msg == NULL) return NULL; if (wps_build_version(msg) || wps_build_msg_type(msg, WPS_WSC_NACK) || wps_build_enrollee_nonce(wps, msg) ...
wps_build_wsc_nack
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_button_pushed(hostapd_data *hapd, void *ctx) { if (!hapd->wps) return 0; ++*((_DWORD *)ctx + 2); return wps_registrar_button_pushed(hapd->wps->registrar, *(const u8 **)ctx); }
static int wps_button_pushed(struct hostapd_data *hapd, void *ctx) { struct wps_button_pushed_ctx *data = ctx; if (hapd->wps) { data->count++; return wps_registrar_button_pushed(hapd->wps->registrar, data->p2p_dev_addr); } return 0; }
wps_button_pushed
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_cancel(hostapd_data *hapd, void *ctx) { if (hapd->wps) { ++*(_DWORD *)ctx; wps_registrar_wps_cancel(hapd->wps->registrar); ap_for_each_sta( hapd, (int (*)(hostapd_data *, sta_info *, void *))ap_sta_wps_cancel, 0); wpa_msg(hapd->msg_ctx, 3, "WPS-CANCEL "); } return 0; }
static int wps_cancel(struct hostapd_data *hapd, void *ctx) { struct wps_cancel_ctx *data = ctx; if (hapd->wps) { data->count++; wps_registrar_wps_cancel(hapd->wps->registrar); ap_for_each_sta(hapd, ap_sta_wps_cancel, NULL); wpa_msg(hapd->msg_ctx, MSG_INFO, WPS_EVENT_CANCEL); } return 0; }
wps_cancel
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_cb_new_psk(wps_registrar *reg, const u8 *mac_addr, const u8 *p2p_dev_addr, const u8 *psk, size_t psk_len) { if (reg->new_psk_cb) return reg->new_psk_cb(reg->cb_ctx, mac_addr, p2p_dev_addr, psk, psk_len); else return 0; }
int wps_cb_new_psk(struct wps_registrar *reg, const u8 *mac_addr, const u8 *p2p_dev_addr, const u8 *psk, size_t psk_len) { if (reg->new_psk_cb == NULL) return 0; return reg->new_psk_cb(reg->cb_ctx, mac_addr, p2p_dev_addr, psk, psk_len); }
wps_cb_new_psk
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_cb_pin_needed(wps_registrar *reg, const u8 *uuid_e, const wps_device_data *dev) { if (reg->pin_needed_cb) reg->pin_needed_cb(reg->cb_ctx, uuid_e, dev); }
static void wps_cb_pin_needed(struct wps_registrar *reg, const u8 *uuid_e, const struct wps_device_data *dev) { if (reg->pin_needed_cb == NULL) return; reg->pin_needed_cb(reg->cb_ctx, uuid_e, dev); }
wps_cb_pin_needed
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_cb_reg_success(wps_registrar *reg, const u8 *mac_addr, const u8 *uuid_e, const u8 *dev_pw, size_t dev_pw_len) { if (reg->reg_success_cb) reg->reg_success_cb(reg->cb_ctx, mac_addr, uuid_e, dev_pw, dev_pw_len); }
static void wps_cb_reg_success(struct wps_registrar *reg, const u8 *mac_addr, const u8 *uuid_e, const u8 *dev_pw, size_t dev_pw_len) { if (reg->reg_success_cb == NULL) return; reg->reg_success_cb(reg->cb_ctx, mac_addr, uuid_e, dev_pw, dev_pw_len); }
wps_cb_reg_success
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_cb_set_ie(wps_registrar *reg, wpabuf *beacon_ie, wpabuf *probe_resp_ie) { return reg->set_ie_cb(reg->cb_ctx, beacon_ie, probe_resp_ie); }
static int wps_cb_set_ie(struct wps_registrar *reg, struct wpabuf *beacon_ie, struct wpabuf *probe_resp_ie) { return reg->set_ie_cb(reg->cb_ctx, beacon_ie, probe_resp_ie); }
wps_cb_set_ie
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_cb_set_sel_reg(wps_registrar *reg) { u16 config_methods; int v2; u16 methods; unsigned long v5; v5 = __readfsqword(0x28u); methods = 0; if (reg->set_sel_reg_cb) { if (reg->selected_registrar) { config_methods = reg->wps->config_methods; LOBYTE(config_methods) = config_methods & 0...
static void wps_cb_set_sel_reg(struct wps_registrar *reg) { u16 methods = 0; if (reg->set_sel_reg_cb == NULL) return; if (reg->selected_registrar) { methods = reg->wps->config_methods & ~WPS_CONFIG_PUSHBUTTON; methods &= ~(WPS_CONFIG_VIRT_PUSHBUTTON | WPS_CONFIG_PHY_PUSHBUTTON); if (reg->pbc) ...
wps_cb_set_sel_reg
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
u16 wps_config_methods_str2bin(const char *str) { u16 methods; methods = 0; if (!str || !*str) return 8520; if (strstr(str, "ethernet")) methods = 2; if (strstr(str, "label")) methods |= 4u; if (strstr(str, "display")) methods |= 8u; if (strstr(str, "ext_nfc_token")) methods |= 0x10u;...
u16 wps_config_methods_str2bin(const char *str) { u16 methods = 0; if (str == NULL || str[0] == '\0') { methods |= WPS_CONFIG_DISPLAY | WPS_CONFIG_KEYPAD; methods |= WPS_CONFIG_VIRT_DISPLAY; #ifdef CONFIG_WPS_NFC methods |= WPS_CONFIG_NFC_INTERFACE; #endif #ifdef CONFIG_P2P methods |= WPS_CONFIG_P...
wps_config_methods_str2bin
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_cp_lookup_pskfile(wps_registrar *reg, const u8 *mac_addr, const u8 **psk) { if (reg->lookup_pskfile_cb) return reg->lookup_pskfile_cb(reg->cb_ctx, mac_addr, psk); else return 0; }
static int wps_cp_lookup_pskfile(struct wps_registrar *reg, const u8 *mac_addr, const u8 **psk) { if (!reg->lookup_pskfile_cb) return 0; return reg->lookup_pskfile_cb(reg->cb_ctx, mac_addr, psk); }
wps_cp_lookup_pskfile
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_decrypt_encr_settings(wps_data *wps, const u8 *encr, size_t encr_len) { size_t v4; u8 *v5; const u8 *v6; size_t v7; const u8 *v8; u8 pad; size_t i; const u8 *pos; wpabuf *decrypted; if (encr && encr_len >= 0x20 && !(encr_len % 0x10)) { decrypted = w...
struct wpabuf *wps_decrypt_encr_settings(struct wps_data *wps, const u8 *encr, size_t encr_len) { struct wpabuf *decrypted; const size_t block_size = 16; size_t i; u8 pad; const u8 *pos; if (encr == NULL || encr_len < 2 * block_size || encr_len % block_size) { w...
wps_decrypt_encr_settings
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_deinit(wps_data *data) { if (data->registrar && data->nfc_pw_token) wps_registrar_remove_nfc_pw_token(data->wps->registrar, data->nfc_pw_token); if (data->wps_pin_revealed) { wpa_printf(2, "WPS: Full PIN information revealed and negotiation failed"); if (data->registrar) wps_registrar_inv...
void wps_deinit(struct wps_data *data) { #ifdef CONFIG_WPS_NFC if (data->registrar && data->nfc_pw_token) wps_registrar_remove_nfc_pw_token(data->wps->registrar, data->nfc_pw_token); #endif if (data->wps_pin_revealed) { wpa_printf(MSG_DEBUG, "WPS: Full PIN information revealed and " ...
wps_deinit
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_derive_keys(wps_data *wps) { wpabuf *dh_pubkey_e; long v3; wpabuf *pubkey; wpabuf *dh_shareda; wpabuf *dh_shared; const u8 *addr[3]; size_t len[4]; u8 dhkey[32]; u8 kdk[32]; u8 keys[80]; unsigned long v12; v12 = __readfsqword(0x28u); if (wps->dh_privkey) { if (wps->registrar) ...
int wps_derive_keys(struct wps_data *wps) { struct wpabuf *pubkey, *dh_shared; u8 dhkey[SHA256_MAC_LEN], kdk[SHA256_MAC_LEN]; const u8 *addr[3]; size_t len[3]; u8 keys[WPS_AUTHKEY_LEN + WPS_KEYWRAPKEY_LEN + WPS_EMSK_LEN]; if (wps->dh_privkey == NULL) { wpa_printf(MSG_DEBUG, "WPS: Own DH private key not...
wps_derive_keys
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_derive_psk(wps_data *wps, const u8 *dev_passwd, size_t dev_passwd_len) { long v4; long v5; u8 hash[32]; unsigned long v8; v8 = __readfsqword(0x28u); if (hmac_sha256(wps->authkey, 0x20u, dev_passwd, (dev_passwd_len + 1) >> 1, hash) < 0) return -1; v4 = *(_QWORD *)&hash[8]; ...
int wps_derive_psk(struct wps_data *wps, const u8 *dev_passwd, size_t dev_passwd_len) { u8 hash[SHA256_MAC_LEN]; if (hmac_sha256(wps->authkey, WPS_AUTHKEY_LEN, dev_passwd, (dev_passwd_len + 1) / 2, hash) < 0) return -1; os_memcpy(wps->psk1, hash, WPS_PSK_LEN); if (hmac_...
wps_derive_psk
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
char *wps_dev_type_bin2str(const u8 *dev_type, char *buf, size_t buf_len) { int v3; u32 v4; u16 v5; int v6; v3 = WPA_GET_BE16_13(dev_type + 6); v4 = WPA_GET_BE32_9(dev_type + 2); v5 = WPA_GET_BE16_13(dev_type); v6 = snprintf(buf, buf_len, "%u-%08X-%u", v5, v4, v3); if (os_snprintf_error_19(buf_len, v...
char *wps_dev_type_bin2str(const u8 dev_type[WPS_DEV_TYPE_LEN], char *buf, size_t buf_len) { int ret; ret = os_snprintf(buf, buf_len, "%u-%08X-%u", WPA_GET_BE16(dev_type), WPA_GET_BE32(&dev_type[2]), WPA_GET_BE16(&dev_type[6])); if (os_snprintf_error(buf_len, ret)) ...
wps_dev_type_bin2str
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_dev_type_str2bin(const char *str, u8 *dev_type) { u16 v2; u16 v4; char *pos; const char *posa; char *posb; v2 = atoi(str); WPA_PUT_BE16_13(dev_type, v2); pos = strchr(str, 45); if (!pos) return -1; posa = pos + 1; if (hexstr2bin(posa, dev_type + 2, 4u)) return -1; posb = strchr(...
int wps_dev_type_str2bin(const char *str, u8 dev_type[WPS_DEV_TYPE_LEN]) { const char *pos; WPA_PUT_BE16(dev_type, atoi(str)); pos = os_strchr(str, '-'); if (pos == NULL) return -1; pos++; if (hexstr2bin(pos, &dev_type[2], 4)) return -1; pos = os_strchr(pos, '-'); if (pos == NULL) return -1...
wps_dev_type_str2bin
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_device_data_free(wps_device_data *dev) { free(dev->device_name); dev->device_name = 0; free(dev->manufacturer); dev->manufacturer = 0; free(dev->model_name); dev->model_name = 0; free(dev->model_number); dev->model_number = 0; free(dev->serial_number); dev->serial_number = 0; wpabuf_free(...
void wps_device_data_free(struct wps_device_data *dev) { os_free(dev->device_name); dev->device_name = NULL; os_free(dev->manufacturer); dev->manufacturer = NULL; os_free(dev->model_name); dev->model_name = NULL; os_free(dev->model_number); dev->model_number = NULL; os_free(dev->serial_number); dev-...
wps_device_data_free
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_device_store(wps_registrar *reg, wps_device_data *dev, const u8 *uuid) { long v4; wps_registrar_device *d; d = wps_device_get(reg, dev->mac_addr); if (!d) { d = (wps_registrar_device *)os_zalloc(0xF0u); if (!d) return -1; d->next = reg->devices; reg->devices = d; } wps_device_...
int wps_device_store(struct wps_registrar *reg, struct wps_device_data *dev, const u8 *uuid) { struct wps_registrar_device *d; d = wps_device_get(reg, dev->mac_addr); if (d == NULL) { d = os_zalloc(sizeof(*d)); if (d == NULL) return -1; d->next = reg->devices; reg->devi...
wps_device_store
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
const char *wps_ei_str(wps_error_indication ei) { if (ei == wps_error_indication_WPS_EI_AUTH_FAILURE) return "Authentication Failure"; if ((unsigned int)ei > wps_error_indication_WPS_EI_AUTH_FAILURE) return "Unknown"; if (ei == wps_error_indication_WPS_EI_SECURITY_WEP_PROHIBITED) return "WEP Prohibite...
const char *wps_ei_str(enum wps_error_indication ei) { switch (ei) { case WPS_EI_NO_ERROR: return "No Error"; case WPS_EI_SECURITY_TKIP_ONLY_PROHIBITED: return "TKIP Only Prohibited"; case WPS_EI_SECURITY_WEP_PROHIBITED: return "WEP Prohibited"; case WPS_EI_AUTH_FAILURE: return "Authentication...
wps_ei_str
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_enrollee_get_msg(wps_data *wps, wsc_op_code *op_code) { wpabuf *msg; switch (wps->state) { case SEND_M1: msg = wps_build_m1(wps); *op_code = wsc_op_code_WSC_MSG; break; case SEND_M3: msg = wps_build_m3(wps); *op_code = wsc_op_code_WSC_MSG; break; case SEND_M5: msg = wp...
struct wpabuf *wps_enrollee_get_msg(struct wps_data *wps, enum wsc_op_code *op_code) { struct wpabuf *msg; switch (wps->state) { case SEND_M1: msg = wps_build_m1(wps); *op_code = WSC_MSG; break; case SEND_M3: msg = wps_build_m3(wps); *op_code = WSC_MSG; ...
wps_enrollee_get_msg
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_enrollee_process_msg(wps_data *wps, wsc_op_code op_code, const wpabuf *msg) { size_t v3; wsc_op_code op_codea; wps_parse_attr attr; unsigned long v8; op_codea = op_code; v8 = __readfsqword(0x28u); v3 = wpabuf_len_43(msg); wpa_printf(2, "WPS: ...
enum wps_process_res wps_enrollee_process_msg(struct wps_data *wps, enum wsc_op_code op_code, const struct wpabuf *msg) { wpa_printf(MSG_DEBUG, "WPS: Processing received message (len=%lu " "op_code=%...
wps_enrollee_process_msg
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_fail_event(wps_context *wps, wps_msg_type msg, u16 config_error, u16 error_indication, const u8 *mac_addr) { wps_event_data data; unsigned long v9; v9 = __readfsqword(0x28u); if (wps->event_cb) { memset(&data, 0, sizeof(data)); data.fail.msg = msg; data.fail.config_erro...
void wps_fail_event(struct wps_context *wps, enum wps_msg_type msg, u16 config_error, u16 error_indication, const u8 *mac_addr) { union wps_event_data data; if (wps->event_cb == NULL) return; os_memset(&data, 0, sizeof(data)); data.fail.msg = msg; data.fail.config...
wps_fail_event
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_for_each(hostapd_iface *iface, void *ctx) { int ret; size_t j; hostapd_data *hapd; if (!iface) return 0; for (j = 0; j < iface->num_bss; ++j) { hapd = iface->bss[j]; if (hapd == *((hostapd_data **)ctx + 2) || !hapd->conf->wps_independent && !*(_DWORD *)(*(_QWORD *)(*((...
static int wps_for_each(struct hostapd_iface *iface, void *ctx) { struct wps_for_each_data *data = ctx; size_t j; if (iface == NULL) return 0; for (j = 0; j < iface->num_bss; j++) { struct hostapd_data *hapd = iface->bss[j]; int ret; if (hapd != data->calling_hapd && (hapd->conf->wps_i...
wps_for_each
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_free_nfc_pw_tokens(dl_list *tokens, u16 pw_id) { wps_nfc_pw_token *token; wps_nfc_pw_token *prev; token = (wps_nfc_pw_token *)tokens->next; prev = (wps_nfc_pw_token *)tokens->next->next; while (tokens != (dl_list *)token) { if (!pw_id || pw_id == token->pw_id) wps_remove_nfc_pw_token(token...
static void wps_free_nfc_pw_tokens(struct dl_list *tokens, u16 pw_id) { struct wps_nfc_pw_token *token, *prev; dl_list_for_each_safe(token, prev, tokens, struct wps_nfc_pw_token, list) { if (pw_id == 0 || pw_id == token->pw_id) wps_remove_nfc_pw_token(token); } }
wps_free_nfc_pw_tokens
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_free_pin(wps_uuid_pin *pin) { bin_clear_free(pin->pin, pin->pin_len); free(pin); }
static void wps_free_pin(struct wps_uuid_pin *pin) { bin_clear_free(pin->pin, pin->pin_len); os_free(pin); }
wps_free_pin
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_generate_pin(unsigned int *pin) { unsigned int v2; unsigned int val; unsigned long v4; v4 = __readfsqword(0x28u); if (random_get_bytes(&val, 4u) < 0) return -1; val %= 0x989680u; v2 = 10 * val; *pin = v2 + wps_pin_checksum(val); return 0; }
int wps_generate_pin(unsigned int *pin) { unsigned int val; if (random_get_bytes((unsigned char *)&val, sizeof(val)) < 0) return -1; val %= 10000000; *pin = val * 10 + wps_pin_checksum(val); return 0; }
wps_generate_pin
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_get_dev_password(wps_data *wps) { size_t pin_len; const u8 *pin; unsigned long v4; v4 = __readfsqword(0x28u); pin_len = 0; bin_clear_free(wps->dev_password, wps->dev_password_len); wps->dev_password = 0; if (wps->pbc) { wpa_printf(2, "WPS: Use default PIN for PBC"); pin = (const u8 *)"0...
static int wps_get_dev_password(struct wps_data *wps) { const u8 *pin; size_t pin_len = 0; bin_clear_free(wps->dev_password, wps->dev_password_len); wps->dev_password = NULL; if (wps->pbc) { wpa_printf(MSG_DEBUG, "WPS: Use default PIN for PBC"); pin = (const u8 *)"00000000"; pin_len = 8; #ifdef ...
wps_get_dev_password
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_get_msg(wps_data *wps, wsc_op_code *op_code) { if (wps->registrar) return wps_registrar_get_msg(wps, op_code); else return wps_enrollee_get_msg(wps, op_code); }
struct wpabuf *wps_get_msg(struct wps_data *wps, enum wsc_op_code *op_code) { if (wps->registrar) return wps_registrar_get_msg(wps, op_code); else return wps_enrollee_get_msg(wps, op_code); }
wps_get_msg
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_nfc_pw_token *wps_get_nfc_pw_token(dl_list *tokens, u16 pw_id) { wps_nfc_pw_token *token; for (token = (wps_nfc_pw_token *)tokens->next; tokens != (dl_list *)token; token = (wps_nfc_pw_token *)token->list.next) { if (pw_id == token->pw_id) return token; } return 0; }
static struct wps_nfc_pw_token *wps_get_nfc_pw_token(struct dl_list *tokens, u16 pw_id) { struct wps_nfc_pw_token *token; dl_list_for_each(token, tokens, struct wps_nfc_pw_token, list) { if (pw_id == token->pw_id) return token; } return NULL; }
wps_get_nfc_pw_token
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_get_oob_cred(wps_context *wps, int rf_band, int channel) { wpabuf *plain; wps_credential cred; wps_data data; unsigned long v8; v8 = __readfsqword(0x28u); plain = wpabuf_alloc(0x1F4u); if (plain) { memset(&data, 0, sizeof(data)); data.wps = wps; data.auth_type = wps->auth_types; ...
struct wpabuf *wps_get_oob_cred(struct wps_context *wps, int rf_band, int channel) { struct wps_data data; struct wpabuf *plain; plain = wpabuf_alloc(500); if (plain == NULL) { wpa_printf(MSG_ERROR, "WPS: Failed to allocate memory for OOB " "credent...
wps_get_oob_cred
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_ie_encapsulate(wpabuf *data) { size_t v1; const u8 *pos; size_t frag_len; wpabuf *ie; const u8 *end; v1 = wpabuf_len_40(data); ie = wpabuf_alloc(v1 + 100); if (ie) { pos = (const u8 *)wpabuf_head_40(data); end = &pos[wpabuf_len_40(data)]; while (end > pos) { frag_len = end...
struct wpabuf *wps_ie_encapsulate(struct wpabuf *data) { struct wpabuf *ie; const u8 *pos, *end; ie = wpabuf_alloc(wpabuf_len(data) + 100); if (ie == NULL) { wpabuf_free(data); return NULL; } pos = wpabuf_head(data); end = pos + wpabuf_len(data); while (end > pos) { size_t frag_len = end ...
wps_ie_encapsulate
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_data *wps_init(const wps_config *cfg) { long v2; long v3; size_t v4; const void *v5; int v6; wps_data *data; wps_parse_attr attr; unsigned long v9; v9 = __readfsqword(0x28u); data = (wps_data *)os_zalloc(0x378u); if (!data) return 0; data->wps = cfg->wps; data->registrar = cfg->regist...
struct wps_data *wps_init(const struct wps_config *cfg) { struct wps_data *data = os_zalloc(sizeof(*data)); if (data == NULL) return NULL; data->wps = cfg->wps; data->registrar = cfg->registrar; if (cfg->registrar) { os_memcpy(data->uuid_r, cfg->wps->uuid, WPS_UUID_LEN); } else { os_memcpy(data-...
wps_init
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_is_20(const wpabuf *msg) { wps_parse_attr attr; unsigned long v3; v3 = __readfsqword(0x28u); return msg && wps_parse_msg(msg, &attr) >= 0 && attr.version2 != 0; }
int wps_is_20(const struct wpabuf *msg) { struct wps_parse_attr attr; if (msg == NULL || wps_parse_msg(msg, &attr) < 0) return 0; return attr.version2 != NULL; }
wps_is_20
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_is_addr_authorized(const wpabuf *msg, const u8 *addr, int ver1_compat) { unsigned int i; const u8 *pos; wps_parse_attr attr; u8 bcast[6]; unsigned long v9; v9 = __readfsqword(0x28u); memset(bcast, 255, sizeof(bcast)); if (wps_parse_msg(msg, &attr) < 0) return 0; if (!attr.version2 && ver1...
int wps_is_addr_authorized(const struct wpabuf *msg, const u8 *addr, int ver1_compat) { struct wps_parse_attr attr; unsigned int i; const u8 *pos; const u8 bcast[ETH_ALEN] = {0xff, 0xff, 0xff, 0xff, 0xff, 0xff}; if (wps_parse_msg(msg, &attr) < 0) return 0; if (!attr.version2...
wps_is_addr_authorized
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_is_selected_pbc_registrar(const wpabuf *msg) { wps_parse_attr attr; unsigned long v3; v3 = __readfsqword(0x28u); return wps_parse_msg(msg, &attr) >= 0 && attr.selected_registrar && *attr.selected_registrar && attr.dev_password_id && WPA_GET_BE16_12(attr.dev_password_id) == 4; }
int wps_is_selected_pbc_registrar(const struct wpabuf *msg) { struct wps_parse_attr attr; if (wps_parse_msg(msg, &attr) < 0 || !attr.selected_registrar || *attr.selected_registrar == 0 || !attr.dev_password_id || WPA_GET_BE16(attr.dev_password_id) != DEV_PW_PUSHBUTTON) return 0; #ifdef CONFIG_WPS_...
wps_is_selected_pbc_registrar
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_is_selected_pin_registrar(const wpabuf *msg) { wps_parse_attr attr; unsigned long v3; v3 = __readfsqword(0x28u); if (wps_parse_msg(msg, &attr) >= 0) return is_selected_pin_registrar(&attr); else return 0; }
int wps_is_selected_pin_registrar(const struct wpabuf *msg) { struct wps_parse_attr attr; if (wps_parse_msg(msg, &attr) < 0) return 0; return is_selected_pin_registrar(&attr); }
wps_is_selected_pin_registrar
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_kdf(const u8 *key, const u8 *label_prefix, size_t label_prefix_len, const char *label, u8 *res, size_t res_len) { long v6; long v7; signed int i; int iter; u8 *opos; size_t left; const u8 *addr[4]; size_t len[5]; u8 i_buf[4]; u8 key_bits[4]; u8 hash[32]; unsigned long v21; ...
void wps_kdf(const u8 *key, const u8 *label_prefix, size_t label_prefix_len, const char *label, u8 *res, size_t res_len) { u8 i_buf[4], key_bits[4]; const u8 *addr[4]; size_t len[4]; int i, iter; u8 hash[SHA256_MAC_LEN], *opos; size_t left; WPA_PUT_BE32(key_bits, res_len * 8); addr[0] = i...
wps_kdf
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_nfc_gen_dh(wpabuf **pubkey, wpabuf **privkey) { wpabuf *priv; wpabuf *pub; void *dh_ctx; unsigned long v6; v6 = __readfsqword(0x28u); priv = 0; pub = 0; dh_ctx = dh5_init(&priv, &pub); if (!dh_ctx) return -1; pub = wpabuf_zeropad(pub, 0xC0u); if (pub) { wpa_hexdump_buf_6(2, "WPS: ...
int wps_nfc_gen_dh(struct wpabuf **pubkey, struct wpabuf **privkey) { struct wpabuf *priv = NULL, *pub = NULL; void *dh_ctx; dh_ctx = dh5_init(&priv, &pub); if (dh_ctx == NULL) return -1; pub = wpabuf_zeropad(pub, 192); if (pub == NULL) { wpabuf_free(priv); dh5_free(dh_ctx); return -1; } ...
wps_nfc_gen_dh
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_nfc_token_build(int ndef, int id, wpabuf *pubkey, wpabuf *dev_pw) { wpabuf *ret; wpabuf *tmp; if (!pubkey || !dev_pw) return 0; ret = wps_build_nfc_pw_token(id, pubkey, dev_pw); if (ndef && ret) { tmp = ndef_build_wifi(ret); wpabuf_free(ret); if (!tmp) return 0; return t...
struct wpabuf *wps_nfc_token_build(int ndef, int id, struct wpabuf *pubkey, struct wpabuf *dev_pw) { struct wpabuf *ret; if (pubkey == NULL || dev_pw == NULL) return NULL; ret = wps_build_nfc_pw_token(id, pubkey, dev_pw); if (ndef && ret) { struct wpabuf *tmp; tm...
wps_nfc_token_build
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wpabuf *wps_nfc_token_gen(int ndef, int *id, wpabuf **pubkey, wpabuf **privkey, wpabuf **dev_pw) { void *v6; u16 val; wpabuf *pw; unsigned long v12; v12 = __readfsqword(0x28u); pw = wpabuf_alloc(0x20u); if (!pw) return 0; v6 = wpabuf_put(pw, 0x20u); if (random_get_bytes(...
struct wpabuf *wps_nfc_token_gen(int ndef, int *id, struct wpabuf **pubkey, struct wpabuf **privkey, struct wpabuf **dev_pw) { struct wpabuf *pw; u16 val; pw = wpabuf_alloc(WPS_OOB_DEVICE_PASSWORD_LEN); if (pw == NULL) return NULL; if (ra...
wps_nfc_token_gen
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_oob_use_cred(wps_context *wps, wps_parse_attr *attr) { size_t i; wpabuf msg; wps_credential local_cred; wps_parse_attr cattr; unsigned long v7; v7 = __readfsqword(0x28u); for (i = 0; i < attr->num_cred; ++i) { memset(&local_cred, 0, sizeof(local_cred)); wpabuf_set_4(&msg, attr->cred[i], a...
int wps_oob_use_cred(struct wps_context *wps, struct wps_parse_attr *attr) { struct wpabuf msg; size_t i; for (i = 0; i < attr->num_cred; i++) { struct wps_credential local_cred; struct wps_parse_attr cattr; os_memset(&local_cred, 0, sizeof(local_cred)); wpabuf_set(&msg, attr->cred[i], attr->cre...
wps_oob_use_cred
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_parse_msg(const wpabuf *msg, wps_parse_attr *attr) { u16 prev_type; u16 type; u16 len; int i; const u8 *pos; const u8 *posb; const u8 *posa; const u8 *end; prev_type = 0; memset(attr, 0, sizeof(wps_parse_attr)); pos = (const u8 *)wpabuf_head_39(msg); end = &pos[wpabuf_len_39(msg)]; wh...
int wps_parse_msg(const struct wpabuf *msg, struct wps_parse_attr *attr) { const u8 *pos, *end; u16 type, len; #ifdef WPS_WORKAROUNDS u16 prev_type = 0; #endif os_memset(attr, 0, sizeof(*attr)); pos = wpabuf_head(msg); end = pos + wpabuf_len(msg); while (pos < end) { if (end - pos < 4) { wpa_p...
wps_parse_msg
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_parse_vendor_ext(wps_parse_attr *attr, const u8 *pos, u16 len) { u32 vendor_id; if (len > 2u) { vendor_id = WPA_GET_BE24_2(pos); if (vendor_id == 14122) { return wps_parse_vendor_ext_wfa(attr, pos + 3, len - 3); } else { wpa_printf(1, "WPS: Unknown Vendor Extension (Vendor ID %u)", ...
static int wps_parse_vendor_ext(struct wps_parse_attr *attr, const u8 *pos, u16 len) { u32 vendor_id; if (len < 3) { wpa_printf(MSG_DEBUG, "WPS: Skip invalid Vendor Extension"); return 0; } vendor_id = WPA_GET_BE24(pos); switch (vendor_id) { case WPS_VENDOR_ID_WFA: ...
wps_parse_vendor_ext
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_parse_vendor_ext_wfa(wps_parse_attr *attr, const u8 *pos, u16 len) { u8 *v3; u8 *posa; const u8 *posb; u8 id; u8 elen; const u8 *end; posa = (u8 *)pos; end = &pos[len]; while (end - posa > 1) { id = *posa; v3 = posa + 1; posb = posa + 2; elen = *v3; if (*v3 > end - posb) ...
static int wps_parse_vendor_ext_wfa(struct wps_parse_attr *attr, const u8 *pos, u16 len) { const u8 *end = pos + len; u8 id, elen; while (end - pos >= 2) { id = *pos++; elen = *pos++; if (elen > end - pos) break; if (wps_set_vendor_ext_wfa_subelem(attr, i...
wps_parse_vendor_ext_wfa
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_pbc_active_event(wps_context *wps) { if (wps->event_cb) wps->event_cb(wps->cb_ctx, wps_event_WPS_EV_PBC_ACTIVE, 0); }
void wps_pbc_active_event(struct wps_context *wps) { if (wps->event_cb == NULL) return; wps->event_cb(wps->cb_ctx, WPS_EV_PBC_ACTIVE, NULL); }
wps_pbc_active_event
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_pbc_disable_event(wps_context *wps) { if (wps->event_cb) wps->event_cb(wps->cb_ctx, wps_event_WPS_EV_PBC_DISABLE, 0); }
void wps_pbc_disable_event(struct wps_context *wps) { if (wps->event_cb == NULL) return; wps->event_cb(wps->cb_ctx, WPS_EV_PBC_DISABLE, NULL); }
wps_pbc_disable_event
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_pin_str_valid(const char *pin) { char *p; for (p = (char *)pin; *p > 47 && *p <= 57; ++p) ; if (*p) return 0; return p - pin == 4 || p - pin == 8; }
int wps_pin_str_valid(const char *pin) { const char *p; size_t len; p = pin; while (*p >= '0' && *p <= '9') p++; if (*p != '\0') return 0; len = p - pin; return len == 4 || len == 8; }
wps_pin_str_valid
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_ap_settings(wps_parse_attr *attr, wps_credential *cred) { wpa_printf(2, "WPS: Processing AP Settings"); memset(cred, 0, sizeof(wps_credential)); if (wps_process_cred_ssid(cred, attr->ssid, attr->ssid_len) || wps_process_cred_auth_type(cred, attr->auth_type) || wps_process_cred_encr_typ...
int wps_process_ap_settings(struct wps_parse_attr *attr, struct wps_credential *cred) { wpa_printf(MSG_DEBUG, "WPS: Processing AP Settings"); os_memset(cred, 0, sizeof(*cred)); if (wps_process_cred_ssid(cred, attr->ssid, attr->ssid_len) || wps_process_cred_auth_type(cred, attr->...
wps_process_ap_settings
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_ap_settings_e(wps_data *wps, wps_parse_attr *attr, wpabuf *attrs, int wps2) { int ret; wps_credential cred; unsigned long v8; v8 = __readfsqword(0x28u); ret = 0; if (!wps->wps->ap) return 0; if (wps_process_ap_settings(attr, &cred) < 0) return -1; w...
static int wps_process_ap_settings_e(struct wps_data *wps, struct wps_parse_attr *attr, struct wpabuf *attrs, int wps2) { struct wps_credential cred; int ret = 0; if (!wps->wps->ap) return 0; if (wps_process_ap_settings(attr, &cred)...
wps_process_ap_settings_e
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_ap_settings_r(wps_data *wps, wps_parse_attr *attr) { wpabuf *msg; if (wps->wps->ap || wps->er) return 0; if (wps_process_ap_settings(attr, &wps->cred) < 0) return -1; wpa_printf(3, "WPS: Received old AP configuration from AP"); if (wps->new_ap_settings) { wpa_printf(3, "WPS: Updat...
static int wps_process_ap_settings_r(struct wps_data *wps, struct wps_parse_attr *attr) { struct wpabuf *msg; if (wps->wps->ap || wps->er) return 0; if (wps_process_ap_settings(attr, &wps->cred) < 0) return -1; wpa_printf(MSG_INFO, "WPS: Received old AP configurat...
wps_process_ap_settings_r
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_assoc_state(wps_data *wps, const u8 *assoc) { u16 a; if (assoc) { a = WPA_GET_BE16_17(assoc); wpa_printf(2, "WPS: Enrollee Association State %d", a); return 0; } else { wpa_printf(2, "WPS: No Association State received"); return -1; } }
static int wps_process_assoc_state(struct wps_data *wps, const u8 *assoc) { u16 a; if (assoc == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Association State received"); return -1; } a = WPA_GET_BE16(assoc); wpa_printf(MSG_DEBUG, "WPS: Enrollee Association State %d", a); return 0; }
wps_process_assoc_state
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_auth_type_flags(wps_data *wps, const u8 *auth) { u16 auth_types; if (auth) { auth_types = WPA_GET_BE16_17(auth); wpa_printf(2, "WPS: Enrollee Authentication Type flags 0x%x", auth_types); if ((auth_types & 0x32) == 0x12) { wpa_printf(2, "WPS: Workaround - assume Enrollee supports ...
static int wps_process_auth_type_flags(struct wps_data *wps, const u8 *auth) { u16 auth_types; if (auth == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Authentication Type flags " "received"); return -1; } auth_types = WPA_GET_BE16(auth); wpa_printf(MSG_DEBUG, "WPS: Enrollee Aut...
wps_process_auth_type_flags
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_authenticator(wps_data *wps, const u8 *authenticator, const wpabuf *msg) { const u8 *addr[2]; size_t len[2]; u8 hash[40]; unsigned long v8; v8 = __readfsqword(0x28u); if (authenticator) { if (wps->last_msg) { addr[0] = (const u8 *)wpabuf_head_41(wps->...
int wps_process_authenticator(struct wps_data *wps, const u8 *authenticator, const struct wpabuf *msg) { u8 hash[SHA256_MAC_LEN]; const u8 *addr[2]; size_t len[2]; if (authenticator == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Authenticator attribute " "...
wps_process_authenticator
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_config_error(wps_data *wps, const u8 *err) { u16 e; if (err) { e = WPA_GET_BE16_17(err); wpa_printf(2, "WPS: Enrollee Configuration Error %d", e); return 0; } else { wpa_printf(2, "WPS: No Configuration Error received"); return -1; } }
static int wps_process_config_error(struct wps_data *wps, const u8 *err) { u16 e; if (err == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Configuration Error received"); return -1; } e = WPA_GET_BE16(err); wpa_printf(MSG_DEBUG, "WPS: Enrollee Configuration Error %d", e); return 0; }
wps_process_config_error
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_config_methods(wps_data *wps, const u8 *methods) { u16 v3; const char *v4; const char *v5; const char *v6; const char *v7; const char *v8; const char *v9; const char *v10; const char *v11; const char *v12; u16 m; if (methods) { v3 = WPA_GET_BE16_17(methods); m = v3; ...
static int wps_process_config_methods(struct wps_data *wps, const u8 *methods) { u16 m; if (methods == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Config Methods received"); return -1; } m = WPA_GET_BE16(methods); wpa_printf(MSG_DEBUG, "WPS: Enrollee Config Methods 0x%x" "%s%s%...
wps_process_config_methods
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_conn_type_flags(wps_data *wps, const u8 *conn) { if (conn) { wpa_printf(2, "WPS: Enrollee Connection Type flags 0x%x", *conn); return 0; } else { wpa_printf(2, "WPS: No Connection Type flags received"); return -1; } }
static int wps_process_conn_type_flags(struct wps_data *wps, const u8 *conn) { if (conn == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Connection Type flags " "received"); return -1; } wpa_printf(MSG_DEBUG, "WPS: Enrollee Connection Type flags 0x%x", *conn); return 0; }
wps_process_conn_type_flags
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred(wps_parse_attr *attr, wps_credential *cred) { wpa_printf(2, "WPS: Process Credential"); if (wps_process_cred_network_idx(cred, attr->network_idx) || wps_process_cred_ssid(cred, attr->ssid, attr->ssid_len) || wps_process_cred_auth_type(cred, attr->auth_type) || wps_process_cred...
int wps_process_cred(struct wps_parse_attr *attr, struct wps_credential *cred) { wpa_printf(MSG_DEBUG, "WPS: Process Credential"); if (wps_process_cred_network_idx(cred, attr->network_idx) || wps_process_cred_ssid(cred, attr->ssid, attr->ssid_len) || wps_process_cred_auth_type(cred, attr->auth_type) ||...
wps_process_cred
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_auth_type(wps_credential *cred, const u8 *auth_type) { if (auth_type) { cred->auth_type = WPA_GET_BE16_15(auth_type); wpa_printf(2, "WPS: Authentication Type: 0x%x", cred->auth_type); return 0; } else { wpa_printf(2, "WPS: Credential did not include Authentication Type"); re...
static int wps_process_cred_auth_type(struct wps_credential *cred, const u8 *auth_type) { if (auth_type == NULL) { wpa_printf(MSG_DEBUG, "WPS: Credential did not include " "Authentication Type"); return -1; } cred->auth_type = WPA_GET_BE16(a...
wps_process_cred_auth_type
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_e(wps_data *wps, const u8 *cred, size_t cred_len, int wps2) { int ret; wpabuf msg; wps_parse_attr attr; unsigned long v9; v9 = __readfsqword(0x28u); ret = 0; wpa_printf(2, "WPS: Received Credential"); memset(&wps->cred, 0, sizeof(wps->cred)); wpabuf_set_5(&...
static int wps_process_cred_e(struct wps_data *wps, const u8 *cred, size_t cred_len, int wps2) { struct wps_parse_attr attr; struct wpabuf msg; int ret = 0; wpa_printf(MSG_DEBUG, "WPS: Received Credential"); os_memset(&wps->cred, 0, sizeof(wps->cred)); wpabuf_set(&msg, cred, c...
wps_process_cred_e
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_encr_type(wps_credential *cred, const u8 *encr_type) { if (encr_type) { cred->encr_type = WPA_GET_BE16_15(encr_type); wpa_printf(2, "WPS: Encryption Type: 0x%x", cred->encr_type); return 0; } else { wpa_printf(2, "WPS: Credential did not include Encryption Type"); return -1;...
static int wps_process_cred_encr_type(struct wps_credential *cred, const u8 *encr_type) { if (encr_type == NULL) { wpa_printf(MSG_DEBUG, "WPS: Credential did not include " "Encryption Type"); return -1; } cred->encr_type = WPA_GET_BE16(encr_...
wps_process_cred_encr_type
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_mac_addr(wps_credential *cred, const u8 *mac_addr) { if (mac_addr) { wpa_printf(2, "WPS: MAC Address %02x:%02x:%02x:%02x:%02x:%02x", *mac_addr, mac_addr[1], mac_addr[2], mac_addr[3], mac_addr[4], mac_addr[5]); memcpy(cred->mac_addr, mac_addr, sizeof(cred->mac_addr)); re...
static int wps_process_cred_mac_addr(struct wps_credential *cred, const u8 *mac_addr) { if (mac_addr == NULL) { wpa_printf(MSG_DEBUG, "WPS: Credential did not include " "MAC Address"); return -1; } wpa_printf(MSG_DEBUG, "WPS: MAC Address " MA...
wps_process_cred_mac_addr
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_network_idx(wps_credential *cred, const u8 *idx) { if (idx) { wpa_printf(2, "WPS: Network Index: %d", *idx); return 0; } else { wpa_printf(2, "WPS: Credential did not include Network Index"); return -1; } }
static int wps_process_cred_network_idx(struct wps_credential *cred, const u8 *idx) { if (idx == NULL) { wpa_printf(MSG_DEBUG, "WPS: Credential did not include " "Network Index"); return -1; } wpa_printf(MSG_DEBUG, "WPS: Network Index: %d"...
wps_process_cred_network_idx
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_network_key(wps_credential *cred, const u8 *key, size_t key_len) { if (key) { wpa_hexdump_key(2, "WPS: Network Key", key, key_len); if (key_len <= 0x40) { memcpy(cred->key, key, key_len); cred->key_len = key_len; } return 0; } else { ...
static int wps_process_cred_network_key(struct wps_credential *cred, const u8 *key, size_t key_len) { if (key == NULL) { wpa_printf(MSG_DEBUG, "WPS: Credential did not include " "Network Key"); if (cred->auth_type == WPS_AUTH_OPEN && cred->encr...
wps_process_cred_network_key
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_network_key_idx(wps_credential *cred, const u8 *key_idx) { if (key_idx) { wpa_printf(2, "WPS: Network Key Index: %d", *key_idx); cred->key_idx = *key_idx; } return 0; }
static int wps_process_cred_network_key_idx(struct wps_credential *cred, const u8 *key_idx) { if (key_idx == NULL) return 0; wpa_printf(MSG_DEBUG, "WPS: Network Key Index: %d", *key_idx); cred->key_idx = *key_idx; return 0; }
wps_process_cred_network_key_idx
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_cred_ssid(wps_credential *cred, const u8 *ssid, size_t ssid_len) { if (ssid) { while (ssid_len && !ssid[ssid_len - 1]) --ssid_len; wpa_hexdump_ascii(2, "WPS: SSID", ssid, ssid_len); if (ssid_len <= 0x20) { memcpy(cred, ssid, ssid_len); cred->ssid...
static int wps_process_cred_ssid(struct wps_credential *cred, const u8 *ssid, size_t ssid_len) { if (ssid == NULL) { wpa_printf(MSG_DEBUG, "WPS: Credential did not include SSID"); return -1; } while (ssid_len > 0 && ssid[ssid_len - 1] == 0) ssid_len--; wpa_hexdump_...
wps_process_cred_ssid
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_creds(wps_data *wps, const u8 **cred, u16 *cred_len, unsigned int num_cred, int wps2) { int ok; int res; size_t i; ok = 0; if (wps->wps->ap) return 0; if (num_cred) { for (i = 0; i < num_cred; ++i) { res = wps_process_cred_e(wps, cred[i], cred_len[i], wps...
static int wps_process_creds(struct wps_data *wps, const u8 *cred[], u16 cred_len[], unsigned int num_cred, int wps2) { size_t i; int ok = 0; if (wps->wps->ap) return 0; if (num_cred == 0) { wpa_printf(MSG_DEBUG, "WPS: No Credential attributes " "...
wps_process_creds
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_dev_name(wps_device_data *dev, const u8 *str, size_t str_len) { if (str) { wpa_hexdump_ascii(2, "WPS: Device Name", str, str_len); free(dev->device_name); dev->device_name = dup_binstr(str, str_len); if (dev->device_name) return 0; else return -1; } else { wpa_pri...
static int wps_process_dev_name(struct wps_device_data *dev, const u8 *str, size_t str_len) { if (str == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Device Name received"); return -1; } wpa_hexdump_ascii(MSG_DEBUG, "WPS: Device Name", str, str_len); os_free(dev->device_name)...
wps_process_dev_name
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_dev_password_id(wps_data *wps, const u8 *pw_id) { if (pw_id) { wps->dev_pw_id = WPA_GET_BE16_17(pw_id); wpa_printf(2, "WPS: Device Password ID %d", wps->dev_pw_id); return 0; } else { wpa_printf(2, "WPS: No Device Password ID received"); return -1; } }
static int wps_process_dev_password_id(struct wps_data *wps, const u8 *pw_id) { if (pw_id == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Device Password ID received"); return -1; } wps->dev_pw_id = WPA_GET_BE16(pw_id); wpa_printf(MSG_DEBUG, "WPS: Device Password ID %d", wps->dev_pw_id); return 0; }
wps_process_dev_password_id
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_dev_pw_id(wps_data *wps, const u8 *dev_pw_id) { u16 id; if (dev_pw_id) { id = WPA_GET_BE16_16(dev_pw_id); if (id == wps->dev_pw_id) { wpa_printf(2, "WPS: Device Password ID %u", id); return 0; } else { wpa_printf( 2, "WPS: Registrar trying to change Device Pa...
static int wps_process_dev_pw_id(struct wps_data *wps, const u8 *dev_pw_id) { u16 id; if (dev_pw_id == NULL) { wpa_printf(MSG_DEBUG, "WPS: Device Password ID"); return -1; } id = WPA_GET_BE16(dev_pw_id); if (wps->dev_pw_id == id) { wpa_printf(MSG_DEBUG, "WPS: Device Password ID %u", id); ret...
wps_process_dev_pw_id
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_e_hash1(wps_data *wps, const u8 *e_hash1) { if (e_hash1) { memcpy(wps->peer_hash1, e_hash1, sizeof(wps->peer_hash1)); wpa_hexdump(2, "WPS: E-Hash1", wps->peer_hash1, 0x20u); return 0; } else { wpa_printf(2, "WPS: No E-Hash1 received"); return -1; } }
static int wps_process_e_hash1(struct wps_data *wps, const u8 *e_hash1) { if (e_hash1 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No E-Hash1 received"); return -1; } os_memcpy(wps->peer_hash1, e_hash1, WPS_HASH_LEN); wpa_hexdump(MSG_DEBUG, "WPS: E-Hash1", wps->peer_hash1, WPS_HASH_LEN); return 0; }
wps_process_e_hash1
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_e_hash2(wps_data *wps, const u8 *e_hash2) { if (e_hash2) { memcpy(wps->peer_hash2, e_hash2, sizeof(wps->peer_hash2)); wpa_hexdump(2, "WPS: E-Hash2", wps->peer_hash2, 0x20u); return 0; } else { wpa_printf(2, "WPS: No E-Hash2 received"); return -1; } }
static int wps_process_e_hash2(struct wps_data *wps, const u8 *e_hash2) { if (e_hash2 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No E-Hash2 received"); return -1; } os_memcpy(wps->peer_hash2, e_hash2, WPS_HASH_LEN); wpa_hexdump(MSG_DEBUG, "WPS: E-Hash2", wps->peer_hash2, WPS_HASH_LEN); return 0; }
wps_process_e_hash2
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_e_snonce1(wps_data *wps, const u8 *e_snonce1) { const u8 *addr[4]; size_t len[4]; u8 hash[40]; unsigned long v6; v6 = __readfsqword(0x28u); if (e_snonce1) { wpa_hexdump_key(2, "WPS: E-SNonce1", e_snonce1, 0x10u); addr[0] = e_snonce1; len[0] = 16; addr[1] = wps->psk1; len...
static int wps_process_e_snonce1(struct wps_data *wps, const u8 *e_snonce1) { u8 hash[SHA256_MAC_LEN]; const u8 *addr[4]; size_t len[4]; if (e_snonce1 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No E-SNonce1 received"); return -1; } wpa_hexdump_key(MSG_DEBUG, "WPS: E-SNonce1", e_snonce1, WPS_SECRET_NON...
wps_process_e_snonce1
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_e_snonce2(wps_data *wps, const u8 *e_snonce2) { const u8 *addr[4]; size_t len[4]; u8 hash[40]; unsigned long v6; v6 = __readfsqword(0x28u); if (e_snonce2) { wpa_hexdump_key(2, "WPS: E-SNonce2", e_snonce2, 0x10u); addr[0] = e_snonce2; len[0] = 16; addr[1] = wps->psk2; len...
static int wps_process_e_snonce2(struct wps_data *wps, const u8 *e_snonce2) { u8 hash[SHA256_MAC_LEN]; const u8 *addr[4]; size_t len[4]; if (e_snonce2 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No E-SNonce2 received"); return -1; } wpa_hexdump_key(MSG_DEBUG, "WPS: E-SNonce2", e_snonce2, WPS_SECRET_NON...
wps_process_e_snonce2
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_encr_type_flags(wps_data *wps, const u8 *encr) { u16 encr_types; if (encr) { encr_types = WPA_GET_BE16_17(encr); wpa_printf(2, "WPS: Enrollee Encryption Type flags 0x%x", encr_types); wps->encr_type = encr_types & wps->wps->encr_types; if (!wps->encr_type) { wpa_printf(2, ...
static int wps_process_encr_type_flags(struct wps_data *wps, const u8 *encr) { u16 encr_types; if (encr == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Encryption Type flags " "received"); return -1; } encr_types = WPA_GET_BE16(encr); wpa_printf(MSG_DEBUG, "WPS: Enrollee Encrypt...
wps_process_encr_type_flags
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_key_wrap_auth(wps_data *wps, wpabuf *msg, const u8 *key_wrap_auth) { const u8 *head; size_t len; u8 hash[40]; unsigned long v8; v8 = __readfsqword(0x28u); if (key_wrap_auth) { head = (const u8 *)wpabuf_head_41(msg); len = wpabuf_len_41(msg) - 12; if...
int wps_process_key_wrap_auth(struct wps_data *wps, struct wpabuf *msg, const u8 *key_wrap_auth) { u8 hash[SHA256_MAC_LEN]; const u8 *head; size_t len; if (key_wrap_auth == NULL) { wpa_printf(MSG_DEBUG, "WPS: No KWA in decrypted attribute"); return -1; } head = wpabuf...
wps_process_key_wrap_auth
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m1(wps_data *wps, wps_parse_attr *attr) { size_t len; wps_nfc_pw_token *token; const u8 *addr[1]; u8 hash[40]; unsigned long v7; v7 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M1"); if (wps->state != RECV_M1) { wpa_printf(2, "WPS: Unexpected state (%d) for recei...
static enum wps_process_res wps_process_m1(struct wps_data *wps, struct wps_parse_attr *attr) { wpa_printf(MSG_DEBUG, "WPS: Received M1"); if (wps->state != RECV_M1) { wpa_printf(MSG_DEBUG, "WPS: Unexpected state (%d) for " "receiving M1"...
wps_process_m1
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m2(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { wpabuf *decrypted; wps_parse_attr eattr; unsigned long v7; v7 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M2"); if (wps->state == RECV_M2) { if (wps_process_registrar_nonce(w...
static enum wps_process_res wps_process_m2(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { wpa_printf(MSG_DEBUG, "WPS: Received M2"); if (wps->state != RECV_M2) { wpa_printf(MSG_DEBUG, ...
wps_process_m2
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m2d(wps_data *wps, wps_parse_attr *attr) { wps_event_data data; unsigned long v4; v4 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M2D"); if (wps->state == RECV_M2) { wpa_hexdump_ascii(2, "WPS: Manufacturer", attr->manufacturer, attr->manufacturer_...
static enum wps_process_res wps_process_m2d(struct wps_data *wps, struct wps_parse_attr *attr) { wpa_printf(MSG_DEBUG, "WPS: Received M2D"); if (wps->state != RECV_M2) { wpa_printf(MSG_DEBUG, "WPS: Unexpected state (%d) for " "receiving ...
wps_process_m2d
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m3(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { wpa_printf(2, "WPS: Received M3"); if (wps->state == RECV_M3) { if (wps->pbc && wps->wps->registrar->force_pbc_overlap && !wps_registrar_skip_overlap(wps)) { wpa_printf(2, "WPS: ...
static enum wps_process_res wps_process_m3(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { wpa_printf(MSG_DEBUG, "WPS: Received M3"); if (wps->state != RECV_M3) { wpa_printf(MSG_DEBUG, ...
wps_process_m3
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m4(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { wpabuf *decrypted; wps_parse_attr eattr; unsigned long v7; v7 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M4"); if (wps->state == RECV_M4) { if (wps_process_enrollee_nonce(wp...
static enum wps_process_res wps_process_m4(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { struct wpabuf *decrypted; struct wps_parse_attr eattr; wpa_printf(MSG_DEBUG, "WPS: Received M4"); if (...
wps_process_m4
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m5(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { wpabuf *decrypted; wps_parse_attr eattr; unsigned long v7; v7 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M5"); if (wps->state == RECV_M5) { if (wps->pbc && wps->wps->registr...
static enum wps_process_res wps_process_m5(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { struct wpabuf *decrypted; struct wps_parse_attr eattr; wpa_printf(MSG_DEBUG, "WPS: Received M5"); if (...
wps_process_m5
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m6(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { wpabuf *decrypted; wps_parse_attr eattr; unsigned long v7; v7 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M6"); if (wps->state == RECV_M6) { if (wps_process_enrollee_nonce(wp...
static enum wps_process_res wps_process_m6(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { struct wpabuf *decrypted; struct wps_parse_attr eattr; wpa_printf(MSG_DEBUG, "WPS: Received M6"); if (...
wps_process_m6
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m7(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { _BOOL4 v4; wpabuf *decrypted; wps_parse_attr eattr; unsigned long v8; v8 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M7"); if (wps->state == RECV_M7) { if (wps->pbc && wps-...
static enum wps_process_res wps_process_m7(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { struct wpabuf *decrypted; struct wps_parse_attr eattr; wpa_printf(MSG_DEBUG, "WPS: Received M7"); if (...
wps_process_m7
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
wps_process_res wps_process_m8(wps_data *wps, const wpabuf *msg, wps_parse_attr *attr) { wpabuf *decrypted; wps_parse_attr eattr; unsigned long v7; v7 = __readfsqword(0x28u); wpa_printf(2, "WPS: Received M8"); if (wps->state == RECV_M8) { if (wps_process_enrollee_nonce(wp...
static enum wps_process_res wps_process_m8(struct wps_data *wps, const struct wpabuf *msg, struct wps_parse_attr *attr) { struct wpabuf *decrypted; struct wps_parse_attr eattr; wpa_printf(MSG_DEBUG, "WPS: Received M8"); if (...
wps_process_m8
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_mac_addr(wps_data *wps, const u8 *mac_addr) { if (mac_addr) { wpa_printf(2, "WPS: Enrollee MAC Address %02x:%02x:%02x:%02x:%02x:%02x", *mac_addr, mac_addr[1], mac_addr[2], mac_addr[3], mac_addr[4], mac_addr[5]); memcpy(wps->mac_addr_e, mac_addr, sizeof(wps->mac_ad...
static int wps_process_mac_addr(struct wps_data *wps, const u8 *mac_addr) { if (mac_addr == NULL) { wpa_printf(MSG_DEBUG, "WPS: No MAC Address received"); return -1; } wpa_printf(MSG_DEBUG, "WPS: Enrollee MAC Address " MACSTR, MAC2STR(mac_addr)); os_memcpy(wps->mac_addr_e, mac_addr, ETH_ALEN); os_mem...
wps_process_mac_addr
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_manufacturer(wps_device_data *dev, const u8 *str, size_t str_len) { if (str) { wpa_hexdump_ascii(2, "WPS: Manufacturer", str, str_len); free(dev->manufacturer); dev->manufacturer = dup_binstr(str, str_len); if (dev->manufacturer) return 0; else ...
static int wps_process_manufacturer(struct wps_device_data *dev, const u8 *str, size_t str_len) { if (str == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Manufacturer received"); return -1; } wpa_hexdump_ascii(MSG_DEBUG, "WPS: Manufacturer", str, str_len); os_free(dev->ma...
wps_process_manufacturer
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_model_name(wps_device_data *dev, const u8 *str, size_t str_len) { if (str) { wpa_hexdump_ascii(2, "WPS: Model Name", str, str_len); free(dev->model_name); dev->model_name = dup_binstr(str, str_len); if (dev->model_name) return 0; else return -...
static int wps_process_model_name(struct wps_device_data *dev, const u8 *str, size_t str_len) { if (str == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Model Name received"); return -1; } wpa_hexdump_ascii(MSG_DEBUG, "WPS: Model Name", str, str_len); os_free(dev->model_name...
wps_process_model_name
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_model_number(wps_device_data *dev, const u8 *str, size_t str_len) { if (str) { wpa_hexdump_ascii(2, "WPS: Model Number", str, str_len); free(dev->model_number); dev->model_number = dup_binstr(str, str_len); if (dev->model_number) return 0; else ...
static int wps_process_model_number(struct wps_device_data *dev, const u8 *str, size_t str_len) { if (str == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Model Number received"); return -1; } wpa_hexdump_ascii(MSG_DEBUG, "WPS: Model Number", str, str_len); os_free(dev->mo...
wps_process_model_number
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_os_version(wps_device_data *dev, const u8 *ver) { if (ver) { dev->os_version = WPA_GET_BE32_10(ver); wpa_printf(2, "WPS: OS Version %08x", dev->os_version); return 0; } else { wpa_printf(2, "WPS: No OS Version received"); return -1; } }
int wps_process_os_version(struct wps_device_data *dev, const u8 *ver) { if (ver == NULL) { wpa_printf(MSG_DEBUG, "WPS: No OS Version received"); return -1; } dev->os_version = WPA_GET_BE32(ver); wpa_printf(MSG_DEBUG, "WPS: OS Version %08x", dev->os_version); return 0; }
wps_process_os_version
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_primary_dev_type(wps_device_data *dev, const u8 *dev_type) { char *v3; char devtype[24]; unsigned long v5; v5 = __readfsqword(0x28u); if (dev_type) { *(_QWORD *)dev->pri_dev_type = *(_QWORD *)dev_type; v3 = wps_dev_type_bin2str(dev->pri_dev_type, devtype, 0x15u); wpa_printf(2, "WP...
static int wps_process_primary_dev_type(struct wps_device_data *dev, const u8 *dev_type) { #ifndef CONFIG_NO_STDOUT_DEBUG char devtype[WPS_DEV_TYPE_BUFSIZE]; #endif if (dev_type == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Primary Device Type received"); return -1; } ...
wps_process_primary_dev_type
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_r_hash1(wps_data *wps, const u8 *r_hash1) { if (r_hash1) { memcpy(wps->peer_hash1, r_hash1, sizeof(wps->peer_hash1)); wpa_hexdump(2, "WPS: R-Hash1", wps->peer_hash1, 0x20u); return 0; } else { wpa_printf(2, "WPS: No R-Hash1 received"); return -1; } }
static int wps_process_r_hash1(struct wps_data *wps, const u8 *r_hash1) { if (r_hash1 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No R-Hash1 received"); return -1; } os_memcpy(wps->peer_hash1, r_hash1, WPS_HASH_LEN); wpa_hexdump(MSG_DEBUG, "WPS: R-Hash1", wps->peer_hash1, WPS_HASH_LEN); return 0; }
wps_process_r_hash1
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_r_hash2(wps_data *wps, const u8 *r_hash2) { if (r_hash2) { memcpy(wps->peer_hash2, r_hash2, sizeof(wps->peer_hash2)); wpa_hexdump(2, "WPS: R-Hash2", wps->peer_hash2, 0x20u); return 0; } else { wpa_printf(2, "WPS: No R-Hash2 received"); return -1; } }
static int wps_process_r_hash2(struct wps_data *wps, const u8 *r_hash2) { if (r_hash2 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No R-Hash2 received"); return -1; } os_memcpy(wps->peer_hash2, r_hash2, WPS_HASH_LEN); wpa_hexdump(MSG_DEBUG, "WPS: R-Hash2", wps->peer_hash2, WPS_HASH_LEN); return 0; }
wps_process_r_hash2
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_r_snonce1(wps_data *wps, const u8 *r_snonce1) { const u8 *addr[4]; size_t len[4]; u8 hash[40]; unsigned long v6; v6 = __readfsqword(0x28u); if (r_snonce1) { wpa_hexdump_key(2, "WPS: R-SNonce1", r_snonce1, 0x10u); addr[0] = r_snonce1; len[0] = 16; addr[1] = wps->psk1; len...
static int wps_process_r_snonce1(struct wps_data *wps, const u8 *r_snonce1) { u8 hash[SHA256_MAC_LEN]; const u8 *addr[4]; size_t len[4]; if (r_snonce1 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No R-SNonce1 received"); return -1; } wpa_hexdump_key(MSG_DEBUG, "WPS: R-SNonce1", r_snonce1, WPS_SECRET_NON...
wps_process_r_snonce1
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_r_snonce2(wps_data *wps, const u8 *r_snonce2) { const u8 *addr[4]; size_t len[4]; u8 hash[40]; unsigned long v6; v6 = __readfsqword(0x28u); if (r_snonce2) { wpa_hexdump_key(2, "WPS: R-SNonce2", r_snonce2, 0x10u); addr[0] = r_snonce2; len[0] = 16; addr[1] = wps->psk2; len...
static int wps_process_r_snonce2(struct wps_data *wps, const u8 *r_snonce2) { u8 hash[SHA256_MAC_LEN]; const u8 *addr[4]; size_t len[4]; if (r_snonce2 == NULL) { wpa_printf(MSG_DEBUG, "WPS: No R-SNonce2 received"); return -1; } wpa_hexdump_key(MSG_DEBUG, "WPS: R-SNonce2", r_snonce2, WPS_SECRET_NON...
wps_process_r_snonce2
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_rf_bands(wps_device_data *dev, const u8 *bands) { if (bands) { dev->rf_bands = *bands; wpa_printf(2, "WPS: Enrollee RF Bands 0x%x", dev->rf_bands); return 0; } else { wpa_printf(2, "WPS: No RF Bands received"); return -1; } }
int wps_process_rf_bands(struct wps_device_data *dev, const u8 *bands) { if (bands == NULL) { wpa_printf(MSG_DEBUG, "WPS: No RF Bands received"); return -1; } dev->rf_bands = *bands; wpa_printf(MSG_DEBUG, "WPS: Enrollee RF Bands 0x%x", dev->rf_bands); return 0; }
wps_process_rf_bands
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_serial_number(wps_device_data *dev, const u8 *str, size_t str_len) { if (str) { wpa_hexdump_ascii(2, "WPS: Serial Number", str, str_len); free(dev->serial_number); dev->serial_number = dup_binstr(str, str_len); if (dev->serial_number) return 0; e...
static int wps_process_serial_number(struct wps_device_data *dev, const u8 *str, size_t str_len) { if (str == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Serial Number received"); return -1; } wpa_hexdump_ascii(MSG_DEBUG, "WPS: Serial Number", str, str_len); os_free(dev...
wps_process_serial_number
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_uuid_e(wps_data *wps, const u8 *uuid_e) { long v3; if (uuid_e) { v3 = *((_QWORD *)uuid_e + 1); *(_QWORD *)wps->uuid_e = *(_QWORD *)uuid_e; *(_QWORD *)&wps->uuid_e[8] = v3; wpa_hexdump(2, "WPS: UUID-E", wps->uuid_e, 0x10u); return 0; } else { wpa_printf(2, "WPS: No UUID-E r...
static int wps_process_uuid_e(struct wps_data *wps, const u8 *uuid_e) { if (uuid_e == NULL) { wpa_printf(MSG_DEBUG, "WPS: No UUID-E received"); return -1; } os_memcpy(wps->uuid_e, uuid_e, WPS_UUID_LEN); wpa_hexdump(MSG_DEBUG, "WPS: UUID-E", wps->uuid_e, WPS_UUID_LEN); return 0; }
wps_process_uuid_e
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_uuid_r(wps_data *wps, const u8 *uuid_r) { long v3; if (uuid_r) { v3 = *((_QWORD *)uuid_r + 1); *(_QWORD *)wps->uuid_r = *(_QWORD *)uuid_r; *(_QWORD *)&wps->uuid_r[8] = v3; wpa_hexdump(2, "WPS: UUID-R", wps->uuid_r, 0x10u); return 0; } else { wpa_printf(2, "WPS: No UUID-R r...
static int wps_process_uuid_r(struct wps_data *wps, const u8 *uuid_r) { if (uuid_r == NULL) { wpa_printf(MSG_DEBUG, "WPS: No UUID-R received"); return -1; } os_memcpy(wps->uuid_r, uuid_r, WPS_UUID_LEN); wpa_hexdump(MSG_DEBUG, "WPS: UUID-R", wps->uuid_r, WPS_UUID_LEN); return 0; }
wps_process_uuid_r
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
void wps_process_vendor_ext_m1(wps_device_data *dev, const u8 ext) { dev->multi_ap_ext = ext; wpa_printf(2, "WPS: Multi-AP extension value %02x", dev->multi_ap_ext); }
void wps_process_vendor_ext_m1(struct wps_device_data *dev, const u8 ext) { dev->multi_ap_ext = ext; wpa_printf(MSG_DEBUG, "WPS: Multi-AP extension value %02x", dev->multi_ap_ext); }
wps_process_vendor_ext_m1
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0
int wps_process_wps_state(wps_data *wps, const u8 *state) { if (state) { wpa_printf(2, "WPS: Enrollee Wi-Fi Protected Setup State %d", *state); return 0; } else { wpa_printf(2, "WPS: No Wi-Fi Protected Setup State received"); return -1; } }
static int wps_process_wps_state(struct wps_data *wps, const u8 *state) { if (state == NULL) { wpa_printf(MSG_DEBUG, "WPS: No Wi-Fi Protected Setup State " "received"); return -1; } wpa_printf(MSG_DEBUG, "WPS: Enrollee Wi-Fi Protected Setup State %d", *state); return 0; }
wps_process_wps_state
hostapd-2.10
net-wireless
O0/net-wireless/hostapd-2.10/hostapd
ida
O0